Repository navigation
Harden Agentless Feature Flags EVP delivery - #12477
gh-worker-dd-mergequeue-cf854d[bot] merged 11 commits into
Conversation
Add capability-gated local discovery, safe sticky direct fallback, shared route state, send-once semantics, and bounded lifecycle handling for Java Feature Flags telemetry. Environment: Datadog workspace
🟢 Java Benchmark SLOs — All performance SLOs passed
PR vs. master results
Commit: Load and DaCapo benchmarks can be triggered manually in the GitLab pipeline. Results will appear in the Benchmarking Platform UI after completion. |
Move identity attribution to a follow-up branch while keeping forwarding-capability requirements explicit and independent of emitted headers. Preserve credential isolation, no-replay coverage, and existing lifecycle hardening. Validation: communication tests 234/234 and feature-flagging-lib tests 279/279 pass; scoped Spotless formatting passes. Environment: Datadog workspace
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
Please try again by commenting @autotest review.
dougqh
left a comment
There was a problem hiding this comment.
🤖 Generated with Claude Code
Environment: Datadog workspace
Gate shutdown instrumentation on tracing or resolved feature flag enablement, and share Agent path joining. Pin recovery generations, discovery concurrency, replay, idle recovery, and disabled-product behavior with regression tests. Environment: Datadog workspace
vjfridge
left a comment
There was a problem hiding this comment.
LGTM! My earlier feedback is addressed, and local tests passed for flag evaluations and both exposure and evaluation telemetry.
I commented one non-blocking P2 follow-up for direct intake timeout initialization, backed by a reproduction and tested fix.
Initialize shared HTTP settings before the direct client is cached when Feature Flagging starts first. Preserve Remote Config and credential-free construction, and cover both event types with real-client regressions. Environment: Datadog workspace
|
/merge |
|
View all feedbacks in Devflow UI.
It will be processed automatically as soon as GitHub reports it as mergeable. View in MergeQueue UI.
The expected merge time in
|
ae26c2b
into
master
Port master #12477 to the SDK and the agent event proxy: - Send each batch once: direct intake no longer retries, the agent proxy uses the send-once client factory and retries only connection refusal, and only with the Remote Configuration source. - Send Remote Configuration events to the fixed Agent EVP v2 endpoint. - Switch to direct intake for good on the first proxy failure, replaying the batch only after a connection refusal or a 404/405 response. - Keep the proxy route when it is the only one, and discover its endpoint again at most once a minute until it recovers.
Port the agent part of master #12477 to the event proxy: use the send-once client factory, send Remote Configuration events to the fixed Agent EVP v2 endpoint with a connection refusal only retry, treat only connection refusals and 404/405 responses as definitive, and keep the proxy route when it is the only one, discovering its endpoint again at most once a minute until it recovers. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Port the agent part of master #12477 to the event proxy: use the send-once client factory, send Remote Configuration events to the fixed Agent EVP v2 endpoint with a connection refusal only retry, treat only connection refusals and 404/405 responses as definitive, and keep the proxy route when it is the only one, discovering its endpoint again at most once a minute until it recovers. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Port the agent part of master #12477 to the event proxy: use the send-once client factory, send Remote Configuration events to the fixed Agent EVP v2 endpoint with a connection refusal only retry, treat only connection refusals and 404/405 responses as definitive, and keep the proxy route when it is the only one, discovering its endpoint again at most once a minute until it recovers. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
feat(ffe): Port the per-subject evaluation telemetry opt-out to the SDK Port master #12884 to the dd-openfeature SDK: the dd_evaluation_telemetry_opt_out context attribute suppresses evaluation events, evaluation metrics and span enrichment for the subject when enabled by Provider.Options.enableEvaluationTelemetryOptOutParameter or DD_FEATURE_FLAGS_EVALUATION_TELEMETRY_PER_SUBJECT_OPT_OUT_ENABLED. Exposures are unchanged. Provider.Options now defaults to a 30 seconds initialization timeout, as on master. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> feat(ffe): Send each Feature Flags event batch once Port the SDK part of master #12477: direct intake no longer retries, and the event proxy fallback switches to direct intake for good on the first proxy failure, replaying the batch only when the proxy definitively did not receive it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> feat(ffe): Flush pending Feature Flags events at application shutdown The runtime now stops at application shutdown: through the new optional ShutdownSource bridge component when the Datadog Java agent provides it, so the agent flushes the SDK before the JVM shutdown hooks run, or from a JVM shutdown hook otherwise. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> refactor(ffe): Make the bridge shutdown component abstract like the others No released agent implements the bridge yet, so the shutdown component needs no default method for compatibility. The no-op bridge returns null, like the other optional components. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> fix(ffe): Share one shutdown budget between the Feature Flags event pipelines The runtime closed the flag evaluation pipeline, waiting up to 5 seconds, before even signaling the exposure pipeline, then waited up to another 800 ms: a stalled final POST could hold the JVM exit for almost 6 seconds and starve the exposures flush. Port the two-phase shutdown of the agent writers: signal both pipelines, then await both against one 800 ms deadline, without interrupting a current or final HTTP request. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> fix(ffe): Fall back to a JVM shutdown hook when the agent shutdown subscription fails A failing agent shutdown subscription escaped the shared runtime acquisition after the runtime started, leaking it and failing the provider initialization. Fall back to the JVM shutdown hook instead. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> fix(ffe): Prevent startup failures with older Java agents by returning caller defaults when the RC connector is unavailable Co-authored-by: sarahchen6 <sarah.chen@datadoghq.com> Co-authored-by: bruce.bujon <bruce.bujon@datadoghq.com>
Port the agent part of master #12477 to the event proxy: use the send-once client factory, send Remote Configuration events to the fixed Agent EVP v2 endpoint with a connection refusal only retry, treat only connection refusals and 404/405 responses as definitive, and keep the proxy route when it is the only one, discovering its endpoint again at most once a minute until it recovers. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Port the agent-side behaviors of the removed writers: send each event batch once with proxy discovery and recovery, and the Java SDK identity headers (#12477, #12575); flush the SDK pending events at agent shutdown, with or without tracing; declare the SDK settings the agent exposes (#12884, #12774). Move the Feature Flags shutdown tests from the agent tests to the OpenFeature smoke tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Port the agent-side behaviors of the removed writers: send each event batch once with proxy discovery and recovery, and the Java SDK identity headers (#12477, #12575); flush the SDK pending events at agent shutdown, with or without tracing; declare the SDK settings the agent exposes (#12884, #12774). Move the Feature Flags shutdown tests from the agent tests to the OpenFeature smoke tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Port the agent-side behaviors of the removed writers: send each event batch once with proxy discovery and recovery, and the Java SDK identity headers (#12477, #12575); flush the SDK pending events at agent shutdown, with or without tracing; declare the SDK settings the agent exposes (#12884, #12774). Move the Feature Flags shutdown tests from the agent tests to the OpenFeature smoke tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Port the agent-side behaviors of the removed writers: send each event batch once with proxy discovery and recovery, and the Java SDK identity headers (#12477, #12575); flush the SDK pending events at agent shutdown, with or without tracing; declare the SDK settings the agent exposes (#12884, #12774). Move the Feature Flags shutdown tests from the agent tests to the OpenFeature smoke tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Port the agent-side behaviors of the removed writers: send each event batch once with proxy discovery and recovery, and the Java SDK identity headers (#12477, #12575); flush the SDK pending events at agent shutdown, with or without tracing; declare the SDK settings the agent exposes (#12884, #12774). Move the Feature Flags shutdown tests from the agent tests to the OpenFeature smoke tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Port the agent-side behaviors of the removed writers: send each event batch once with proxy discovery and recovery, and the Java SDK identity headers (#12477, #12575); flush the SDK pending events at agent shutdown, with or without tracing; declare the SDK settings the agent exposes (#12884, #12774). Move the Feature Flags shutdown tests from the agent tests to the OpenFeature smoke tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Port the agent-side behaviors of the removed writers: send each event batch once with proxy discovery and recovery, and the Java SDK identity headers (#12477, #12575); flush the SDK pending events at agent shutdown, with or without tracing; declare the SDK settings the agent exposes (#12884, #12774). Move the Feature Flags shutdown tests from the agent tests to the OpenFeature smoke tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Port the agent-side behaviors of the removed writers: send each event batch once with proxy discovery and recovery, and the Java SDK identity headers (#12477, #12575); flush the SDK pending events at agent shutdown, with or without tracing; declare the SDK settings the agent exposes (#12884, #12774). Move the Feature Flags shutdown tests from the agent tests to the OpenFeature smoke tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Port the agent-side behaviors of the removed writers: send each event batch once with proxy discovery and recovery, and the Java SDK identity headers (#12477, #12575); flush the SDK pending events at agent shutdown, with or without tracing; declare the SDK settings the agent exposes (#12884, #12774). Move the Feature Flags shutdown tests from the agent tests to the OpenFeature smoke tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Port the agent-side behaviors of the removed writers: send each event batch once with proxy discovery and recovery, and the Java SDK identity headers (#12477, #12575); flush the SDK pending events at agent shutdown, with or without tracing; declare the SDK settings the agent exposes (#12884, #12774). Move the Feature Flags shutdown tests from the agent tests to the OpenFeature smoke tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Motivation
Java already delivers agentless exposures (#12195) and flag evaluations (#12204) directly to EVP. This follow-up closes reliability gaps found while checking the cross-SDK contract: unsafe replay, inconsistent writer routes, lost Agent URL prefixes and permanent disablement when no route exists at startup. Tracks FFLSDK-187.
Changes
Decisions
Validation
3110972ccf744f304a7cf59973e240f9ccd1a071.1b5766b56c67bb7151a084abb752e62e5bb4b332../gradlew :communication:spotlessApply :products:feature-flagging:feature-flagging-lib:spotlessApply :communication:test :products:feature-flagging:feature-flagging-lib:test --console=plain --max-workers=4: PASS; communication 234/234, feature-flagging-lib 279/279.git diff --check: PASS. New scope-reduction commit is GitHub verified:verified=true,reason=valid.e20a9d77c333ddb0c0444835f23fafba70952373and must not be carried forward as current proof.