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

Update middleware function to correctly honor trace headers #115

Merged
merged 13 commits into from
Apr 13, 2023

Conversation

renaz6
Copy link
Member

@renaz6 renaz6 commented Mar 20, 2023

  • With the newest Tr1d1um release, tracing headers can now be sent in WRP messages (which can be sent as Xmidt headers, JSON, or msgpack)
  • This PR updates Candlelight with capability to get the trace headers (if they exist) using the new wrpcontext package. Candlelight then propagates the trace context with this info so that remote spans can be honored and not broken.
  • Also updated the header names to have the correct prefix. Closes Ensure Correct Xmidt Header Usage #117

@renaz6 renaz6 marked this pull request as draft March 20, 2023 23:46
@guardrails
Copy link

guardrails bot commented Mar 20, 2023

All previously detected findings have been fixed. Good job! 👍🎉

We will keep this comment up-to-date as you go along and notify you of any security issues that we identify.


👉 Go to the dashboard for detailed results.

📥 Happy? Share your feedback with us.

@codecov
Copy link

codecov bot commented Mar 20, 2023

Codecov Report

Merging #115 (3388f3f) into main (866e9f7) will decrease coverage by 5.66%.
The diff coverage is 0.00%.

@@            Coverage Diff             @@
##             main     #115      +/-   ##
==========================================
- Coverage   77.20%   71.55%   -5.66%     
==========================================
  Files           4        4              
  Lines         215      232      +17     
==========================================
  Hits          166      166              
- Misses         44       61      +17     
  Partials        5        5              
Flag Coverage Δ
unittests 71.55% <0.00%> (-5.66%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
middleware.go 14.89% <0.00%> (-8.44%) ⬇️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@renaz6 renaz6 self-assigned this Mar 21, 2023
@renaz6 renaz6 marked this pull request as ready for review March 21, 2023 20:53
middleware.go Outdated Show resolved Hide resolved
middleware.go Outdated Show resolved Hide resolved
@sonarcloud
Copy link

sonarcloud bot commented Mar 22, 2023

SonarCloud Quality Gate failed.    Quality Gate failed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

0.0% 0.0% Coverage
0.0% 0.0% Duplication

@renaz6 renaz6 requested a review from schmidtw March 22, 2023 17:26
middleware.go Outdated Show resolved Hide resolved
@renaz6 renaz6 marked this pull request as draft April 6, 2023 17:26
@renaz6 renaz6 changed the title Update middleware function for WRP Formats Update middleware function to correctly honor trace headers Apr 12, 2023
@renaz6 renaz6 marked this pull request as ready for review April 12, 2023 19:47
@renaz6 renaz6 assigned maurafortino and unassigned maurafortino Apr 12, 2023
Copy link
Contributor

@denopink denopink left a comment

Choose a reason for hiding this comment

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

left some questions, but overall lgtm 🍻

middleware.go Outdated Show resolved Hide resolved
middleware.go Outdated Show resolved Hide resolved
CHANGELOG.md Show resolved Hide resolved
@renaz6 renaz6 merged commit 2f3ff5b into main Apr 13, 2023
12 of 14 checks passed
@renaz6 renaz6 deleted the updateMiddleware branch April 13, 2023 18:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Ensure Correct Xmidt Header Usage
5 participants