Skip to content
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

Add: Request ID to rack related events #1111

Closed
wants to merge 2 commits into from

Conversation

tvec
Copy link
Contributor

@tvec tvec commented Nov 24, 2020

Description

  • Moved the initial logic from Add request id to headers if exists #1033 for request_id to shared utils
  • New Feature: Add request_id tags (when present) to Rack event
    • Added to both Sentry::Event & Raven::Event namespaces

Why

Testing

request_id_tags_example

@codecov-io
Copy link

codecov-io commented Nov 24, 2020

Codecov Report

Merging #1111 (c46ef35) into master (44f347e) will increase coverage by 0.01%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1111      +/-   ##
==========================================
+ Coverage   98.04%   98.05%   +0.01%     
==========================================
  Files         144      147       +3     
  Lines        6101     6133      +32     
==========================================
+ Hits         5982     6014      +32     
  Misses        119      119              
Impacted Files Coverage Δ
lib/raven/integrations/rack.rb 97.10% <100.00%> (-0.20%) ⬇️
sentry-ruby/lib/sentry/event.rb 98.98% <100.00%> (+0.03%) ⬆️
sentry-ruby/lib/sentry/interfaces/request.rb 98.00% <100.00%> (-0.15%) ⬇️
sentry-ruby/lib/sentry/utils/request_id.rb 100.00% <100.00%> (ø)
sentry-ruby/spec/sentry/event_spec.rb 100.00% <100.00%> (ø)
sentry-ruby/spec/sentry/utils/request_id_spec.rb 100.00% <100.00%> (ø)
spec/raven/event_spec.rb 97.79% <100.00%> (+0.01%) ⬆️
spec/raven/utils/request_id_spec.rb 100.00% <100.00%> (ø)
... and 1 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 44f347e...c46ef35. Read the comment docs.

- moved request id logic to the shared utils
- add request_id tagging when encountering a Rack related Event
- moved request id logic to the shared utils
- add request_id tagging when encountering a Rack related Event
Copy link
Collaborator

@st0012 st0012 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks for the work 👍

@st0012 st0012 added this to In progress in 4.x via automation Nov 26, 2020
@st0012 st0012 modified the milestone: 4.0.0 Nov 26, 2020
@st0012 st0012 removed this from In progress in 4.x Nov 26, 2020
Copy link
Collaborator

@st0012 st0012 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah sorry, in order to make tracking/reverting the change easier (not likely though, just in case), can you split the changes into 2 PRs? one for each gem.

@tvec
Copy link
Contributor Author

tvec commented Nov 30, 2020

Yep, can do!

EDIT: see #1119 & #1120

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants