You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am seeing a need to be able to apply track functionality based on response codes.
The possible use case I see is stats tracking of API calls by response code.
I am willing to provide a PR if you think it makes sense to integrate with rack-attack.
The text was updated successfully, but these errors were encountered:
flevour
changed the title
Do you agree to support a throttle/track response support?
Would you agree to support a throttle/track response support?
Aug 8, 2014
flevour
changed the title
Would you agree to support a throttle/track response support?
Would you agree to support a track response support?
Aug 8, 2014
@flevour: Interesting. I'm hesitant to expand the track functionality to include responses. Adding tracks for requests was b/c it was such a close fit to how we're already blocking & throttling other requests.
For simplicity and focus, I'd like to keep parsing responses outside the scope of rack-attack. You could implementing response tracking as a separate middleware or gem (per @zmillman's suggesting).
In my case I'd want to throttle only successful requests to API over a given period.
Basically I'm re-using the whole rack-attack count-over-period logic but to throttle responses.
I see your point about simplicity/focus though, thanks for sharing your thoughts!
I am seeing a need to be able to apply track functionality based on response codes.
The possible use case I see is stats tracking of API calls by response code.
I am willing to provide a PR if you think it makes sense to integrate with
rack-attack
.The text was updated successfully, but these errors were encountered: