-
Notifications
You must be signed in to change notification settings - Fork 280
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
Use string instead of symbol when looking up "failsafe" in payload #951
Use string instead of symbol when looking up "failsafe" in payload #951
Conversation
@waltjones cherry-picked your commit from #949 to see if it fixes the Travis build here and check whether this PR is passing. I can remove it if you merge that other PR first 👍 |
@mauro-oto Thank you for the PR. #949 is merged now. |
Unlike ActiveJob, Sidekiq doesn't keep symbols in payloads, and converts them to strings. Because of this, the failsafe mechanism was not working as expected and it was reported in rollbar#950. This PR fixes that by looking up 'failsafe' in the payload instead of :failsafe An example of what the payload looks like when logged in our logs from Rollbar: ``` ERROR -- : [Rollbar] Error processing the item: Net::ReadTimeout, Net::ReadTimeout with #<TCPSocket:(closed)>. Item: {"access_token"=>"abcdefghijklmnop", "data"=>{"level"=>"error", "environment"=>"development", "body"=>{"message"=>{"body"=>"Failsafe from rollbar-gem. Net::ReadTimeout: \"Net::ReadTimeout with #<TCPSocket:(closed)>\" in /usr/local/lib/ruby/2.6.0/net/protocol.rb:217:in `rbuf_fill': error in process_item"}}, "notifier"=>{"name"=>"rollbar-gem", "version"=>"2.24.0"}, "custom"=>{"orig_uuid"=>nil, "orig_host"=>nil}, "internal"=>true, "failsafe"=>true}} ```
c26a192
to
101305b
Compare
@waltjones thanks! just updated this PR to remove the cherry-picked commit from here. |
Can this be merged now? I would really want to see a new release with this feature as this is crucial for our use-case. |
@waltjones any chance you'll merge this today and cut a release? 🙏 |
Please merge soon! This is important for the stability of our production app while using Rollbar. Thank you! |
Yes, if possible this will go out today. |
v2.25.0 is released now. https://github.com/rollbar/rollbar-gem/releases/tag/v2.25.0 |
Unlike ActiveJob, Sidekiq doesn't keep symbols in payloads, and converts them
to strings. Because of this, the failsafe mechanism was not working as expected
as it was reported in #950.
This PR fixes that by always looking up
'failsafe'
in the payload instead of:failsafe
.An example of what the payload looks like when logged from Rollbar: