-
Notifications
You must be signed in to change notification settings - Fork 344
feat(feature-flagging): FFE APM feature-flag span enrichment (experimental, gated) #11658
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
Open
leoromanovsky
wants to merge
24
commits into
master
Choose a base branch
from
leo.romanovsky/ffe-apm-span-enrichment
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+1,949
−14
Open
Changes from all commits
Commits
Show all changes
24 commits
Select commit
Hold shift + click to select a range
411b4f5
feat(02-02): surface UFC split serialId in eval metadata + add span-e…
leoromanovsky c076e23
feat(02-02): ULeb128 codec + accumulator + capture hook + write inter…
leoromanovsky 44f51c5
test(02-02): JUnit 5 L0 suite for span enrichment (7 required cases +…
leoromanovsky 545f72b
fix(02-02): correct span-enrichment lifecycle (partial-flush, leak, r…
leoromanovsky 8491123
test(02-02): regression tests for span-enrichment lifecycle defects
leoromanovsky 35aba86
chore(feature-flagging): strip internal review labels from span-enric…
leoromanovsky 109eab8
fix(feature-flagging): address span-enrichment code-review findings
leoromanovsky c9cc06d
Merge master
pavlokhrebto 7b4da18
Adjustments + clean up; add FeatureFlaggingConfig.SPAN_ENRICHMENT_ENA…
pavlokhrebto d29a8b3
Rework FFE span-enrichment state store to weak-keyed-by-span map
pavlokhrebto 2a6926c
Merge branch 'master' of github.com:DataDog/dd-trace-java into leo.ro…
pavlokhrebto 99422b5
Enhancements after techdebt skill
pavlokhrebto 4be86c6
Refactor: Move span-enrichment write tier out of the published dd-op…
pavlokhrebto ac8195b
Use JsonWriter instead of hand-written solution
pavlokhrebto 77a8ec2
Fix unicode char
pavlokhrebto 5ac008d
Address review nits: gate enrichment metadata, name constants, reuse …
pavlokhrebto 22255cb
feat(ffe): Introduce config module to decouple feature flagging from …
PerfectSlayer 3b3ae47
Fix 3 bugs: SpanEnrichmentWriter is now a process-wide singleton; add…
pavlokhrebto f56665b
Fix nits: add debug logging; fix comments
pavlokhrebto aa31d10
Merge branch 'master' into leo.romanovsky/ffe-apm-span-enrichment
sarahchen6 d3b867a
Add gate on registration; adjust - add typed metadata
pavlokhrebto 8399678
Merge branch 'master' of github.com:DataDog/dd-trace-java into leo.ro…
pavlokhrebto bc2b945
Merge branch 'leo.romanovsky/ffe-apm-span-enrichment' of github.com:D…
pavlokhrebto 2d55eb9
Merge branch 'master' into leo.romanovsky/ffe-apm-span-enrichment
pavlokhrebto File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 0 additions & 6 deletions
6
dd-trace-api/src/main/java/datadog/trace/api/config/FeatureFlaggingConfig.java
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
25 changes: 25 additions & 0 deletions
25
.../feature-flagging-api/src/main/java/datadog/trace/api/openfeature/SpanEnrichmentGate.java
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,25 @@ | ||
| package datadog.trace.api.openfeature; | ||
|
|
||
| import datadog.trace.api.featureflag.config.FeatureFlaggingConfig; | ||
| import datadog.trace.bootstrap.config.provider.ConfigProvider; | ||
|
|
||
| /** | ||
| * Single source for reading the experimental span-enrichment gate, with full {@link ConfigProvider} | ||
| * precedence (system property > stable config > env var {@code | ||
| * DD_EXPERIMENTAL_FLAGGING_PROVIDER_SPAN_ENRICHMENT_ENABLED}). OFF by default; distinct from the | ||
| * provider-enabled gate. Shared so {@link Provider} (per construction) and {@link DDEvaluator} | ||
| * (once at class load) read it the same way. | ||
| */ | ||
| final class SpanEnrichmentGate { | ||
|
|
||
| private SpanEnrichmentGate() {} | ||
|
|
||
| static boolean isEnabled() { | ||
| try { | ||
| return ConfigProvider.getInstance() | ||
| .getBoolean(FeatureFlaggingConfig.EXPERIMENTAL_SPAN_ENRICHMENT_ENABLED, false); | ||
| } catch (final Throwable t) { | ||
| return false; // never let config reading break construction | ||
| } | ||
| } | ||
| } |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Q: Could you explain more about this
overridemode? Why we need it?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's a test-only seam: the
spanEnrichmentEnabledOverrideconstructor param lets tests force the gate on/off deterministically without mutating global config or system properties (when null, the gate is read from config as normal). Not a user-facing feature.