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

router: make shadow requests inherit parent sampling decision by default #37874

Open
wants to merge 7 commits into
base: main
Choose a base branch
from

addressed comments from @wbpcode

bacb67b
Select commit
Loading
Failed to load commit list.
Open

router: make shadow requests inherit parent sampling decision by default #37874

addressed comments from @wbpcode
bacb67b
Select commit
Loading
Failed to load commit list.
CI (Envoy) / Envoy/Prechecks succeeded Jan 8, 2025 in 1h 58m 43s

Envoy/Prechecks (success)

Check has finished

Details

Check run finished (success ✔️)

The check run can be viewed here:

Envoy/Prechecks (pr/37874/main@bacb67b)

Check started by

Request (pr/37874/main@bacb67b)

agrawroh @agrawroh bacb67b #37874 merge main@2425431

router: make shadow requests inherit parent sampling decision by default

Description

This PR changes the behavior of shadow request sampling so that if trace sampling is not explicitly configured in the shadow policy, the shadow request will inherit the parent's sampling decision.

After this change, sampling will follow the trace sampling policy of the original request, which prevents oversampling when runtime sampling is disabled.

Fixes: #37766


Commit Message: router: make shadow requests inherit parent sampling decision by default
Additional Description:
Risk Level: Low
Testing: Added Unit Tests
Docs Changes: Added
Release Notes: Added

Environment

Request variables

Key Value
ref 1070f96
sha bacb67b
pr 37874
base-sha 2425431
actor agrawroh @agrawroh
message router: make shadow requests inherit parent sampling decision by default...
started 1736340528.648285
target-branch main
trusted false
Build image

Container image/s (as used in this CI run)

Key Value
default envoyproxy/envoy-build-ubuntu:d2be0c198feda0c607fa33209da01bf737ef373f
mobile envoyproxy/envoy-build-ubuntu:mobile-d2be0c198feda0c607fa33209da01bf737ef373f
Version

Envoy version (as used in this CI run)

Key Value
major 1
minor 33
patch 0
dev true