Skip to content

chore(gax-internal): inject diagnostic headers conditionally for integration tests#5030

Closed
haphungw wants to merge 1 commit intogoogleapis:mainfrom
haphungw:trace-propagation-e2e-hack
Closed

chore(gax-internal): inject diagnostic headers conditionally for integration tests#5030
haphungw wants to merge 1 commit intogoogleapis:mainfrom
haphungw:trace-propagation-e2e-hack

Conversation

@haphungw
Copy link
Copy Markdown
Contributor

@haphungw haphungw commented Mar 16, 2026

Add a test-only environment variable (GOOGLE_CLOUD_TEST_EXTRA_HEADERS) to generically inject diagnostic headers during execution.

@haphungw haphungw marked this pull request as ready for review March 16, 2026 18:12
@haphungw haphungw requested a review from a team as a code owner March 16, 2026 18:12
@codecov
Copy link
Copy Markdown

codecov bot commented Mar 16, 2026

Codecov Report

❌ Patch coverage is 25.00000% with 6 lines in your changes missing coverage. Please review.
✅ Project coverage is 92.62%. Comparing base (bf48d4f) to head (3ccfcc8).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
src/gax-internal/src/observability/grpc_tracing.rs 25.00% 6 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #5030      +/-   ##
==========================================
- Coverage   92.66%   92.62%   -0.04%     
==========================================
  Files         226      226              
  Lines        8682     8690       +8     
==========================================
+ Hits         8045     8049       +4     
- Misses        637      641       +4     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@haphungw haphungw force-pushed the trace-propagation-e2e-hack branch 3 times, most recently from 70feda2 to e6f0fa9 Compare March 16, 2026 18:45
@haphungw haphungw changed the title chore(gax-internal): inject spanner diagnostic header conditionally chore(gax-internal): inject diagnostic headers conditionally for integration tests Mar 16, 2026
@haphungw haphungw force-pushed the trace-propagation-e2e-hack branch from e6f0fa9 to a82b92c Compare March 16, 2026 18:53
@haphungw haphungw requested a review from westarle March 16, 2026 18:53
…gration tests

Allows setting generic HTTP/gRPC headers via GOOGLE_CLOUD_TEST_EXTRA_HEADERS.
@haphungw haphungw force-pushed the trace-propagation-e2e-hack branch from a82b92c to 2c4412f Compare March 16, 2026 18:56
Copy link
Copy Markdown
Contributor

@westarle westarle left a comment

Choose a reason for hiding this comment

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

I would wait until Spanner Client Library has some public interfaces before checking in changes relating to e2e testing of trace propagation with Spanner. As long as you need to test with a fork or staged PR, the fork or PR might as well contain this change.

Another solution if we get uncomfortable with manual testing before spanner stabilizes might be to add a new feature like #[cfg(google_cloud_spanner_for_trace_test)] in the Spanner client library that (1) reexports needed spanner APIs and (2) hardcodes the header configuration in their client library.

@haphungw
Copy link
Copy Markdown
Contributor Author

included in #5031.

@haphungw haphungw closed this Mar 16, 2026
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.

2 participants