-
-
Notifications
You must be signed in to change notification settings - Fork 521
Failure backoff #267
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Failure backoff #267
Conversation
|
I haven't looked at the code, but huge +1 for getting this into more clients :) |
|
Yeah, it's a blocker to us using sentry in production, we require a circuit breaker or something similar for all 3rd party services. |
|
Hype! You've got some require issues and I haven't looked at the code yet either, but this is great. |
|
ah, looks like timecop (used only in specs) doesn't support ruby 1.8. i'll see what i can do. |
|
hm, that fixes ruby 1.8 but it looks like there's a few failures on the ruby-head builds. are those generally pretty stable? i'll see about installing ruby head locally to try and repro. |
|
@codekitchen They have been fairly stable until now. |
|
We should really allow-failure on ruby-head though :| Take a quick look but don't kill yourself. |
|
OK, I got the latest nightly snapshot installed. I can reproduce the 3 failures locally, but I can also reproduce them on raven-ruby master -- so I think it must be caused by a recent change to ruby head, not related to this change. How would you prefer to proceed? Mark them as allow failure? |
|
Yeah, go ahead and move ruby-head into allow-fail in a separate commit. |
|
sure thing, allow-fail added in https://github.com/getsentry/raven-ruby/pull/268 |
|
Merged, go ahead and rebase. |
This is based on raven-python's implementation, with some tweaks for ruby idioms. With this commit, if we don't send, we only log the event id. I'd like to extend this to log the entire event, along with also logging the entire event when a sending failure occurs.
9e349d0 to
0d60029
Compare
Using timecop to freeze at the *precise* moment where the condition changes can cause problems due to rounding error.
095d8f3 to
e01c9b9
Compare
|
sorry about the spam, i kept forgetting to test ruby 1.8 before pushing |
lib/raven/client.rb
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove the parentheses from any method calls with no arguments.
|
@codekitchen One minor style quibble and then this is mergable. |
|
sure thing, done |
|
Thanks! Appreciate the contribution. |
Failure backoff Close #30
Implements #30
This is based heavily on the raven-python code, with some tweaks to make it more ruby-ish.
Let me know if any changes are needed. I'm not sure if you use a specific ruby styleguide.