Rate limit data returned from API methods
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 32/100
- Tipo di issue
- Funzionalità
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Ferma
- Stack tecnologico
- ruby
- Ambito
- api, authentication
Direzione di ricerca
Non sono indicati file o test. Inizia esaminando i metodi di Authentication and Management API e il modo in cui le risposte vengono attualmente gestite; definisci il callback opzionale per la risposta e il rate limit senza modificare le chiamate esistenti. Il lavoro è completato quando è possibile raccogliere i dati del rate limit da ogni chiamata API, mantenendo compatibile il comportamento originale del metodo.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Checklist
- I have looked into the Readme and Examples, and have not found a suitable solution or answer.
- I have looked into the API documentation and have not found a suitable solution or answer.
- I have searched the issues and have not found a suitable solution or answer.
- I have searched the Auth0 Community forums and have not found a suitable solution or answer.
- I agree to the terms within the Auth0 Code of Conduct.
Describe the problem you'd like to have solved
We're integrating with Auth0 and we would like to gather rate limit data from our calls to the Authentication and Management APIs. We have monitors for when we are rate limited, but we would like to gather metrics on the rate limit data returned from each API call. This would give us clear data points on how close we are to the rate limits as we continue to roll it out to more of our users.
Describe the ideal solution
I've partially implemented this as a proof of concept and I'd be happy to create a pull request for this if you're open to it:
- An optional block can be given to capture the response and rate limit
- The original methods can still be called as is making this a non-breaking change
For example, both of these are valid method calls:
# Original method still works
auth0_client.user_sessions(auth0_id)
# We could use the returned `rate_limit_info` to create Datadog metrics
auth0_client.user_sessions(auth0_id) do |response_body, rate_limit_info|
puts "Response body: #{response_body}"
puts "Rate limit info: #{rate_limit_info}"
end
We're considering monkey patching something like this to gather the rate limit information, but we'd much rather contribute this change if you're open to it!
Alternatives and current workarounds
No response
Additional context
No response
- Lingua principale
- Ruby
- Stelle
- 205
- Fork
- 147
- Merge medio
- 5g 14h
- PR unite (30g)
- 7
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di auth0/ruby-auth0
-
Model#initialize drops every `false` value — booleans are silently lost on requests and responses Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
auth0/ruby-auth0#800 · 1 commento ·
-
feature request
Difficoltà 3/5 1-2 giorni Idoneità per principianti 45/100
auth0/ruby-auth0#709 ·
-
bug
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 50/100
auth0/ruby-auth0#610 · 1 commento ·
-
MFA API Bearer token issue Apertabug
Difficoltà 3/5 1-2 giorni Idoneità per principianti 35/100
auth0/ruby-auth0#556 · 2 commenti ·
-
feature request
Difficoltà 3/5 1-2 giorni Idoneità per principianti 35/100
auth0/ruby-auth0#500 · 1 commento ·
Tutte le issue di auth0/ruby-auth0
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
simp/pupmod-simp-simp#395 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 80/100
simp/pupmod-simp-rsyslog#219 ·
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 90/100
simp/pupmod-simp-pupmod#256 ·
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 90/100
simp/pupmod-simp-sudo#150 ·
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 90/100