test(ffe): add agentless side-effect routing contracts#7299
Draft
leoromanovsky wants to merge 2 commits into
Draft
test(ffe): add agentless side-effect routing contracts#7299leoromanovsky wants to merge 2 commits into
leoromanovsky wants to merge 2 commits into
Conversation
Contributor
|
|
🎉 All green!🧪 All tests passed 🔗 Commit SHA: a4c87ca | Docs | Datadog PR Page | Give us feedback! |
01f97bb to
365973b
Compare
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Motivation
Agentless configuration delivery must not imply Agent-backed side effects. In the target serverless architecture, the SDK prefers a local Datadog serverless sidecar for exposure events, aggregate flag-evaluation events, and evaluation metrics; when no sidecar is available, it falls back to authenticated direct intake.
The previous version of this PR still asserted side effects through
interfaces.agent. That preserved an Agent dependency in the very scenarios intended to prove no-Agent operation. This revision makes the selected telemetry route observable and fails on both missing delivery and delivery through the wrong route.Stack Position
flowchart LR JAVA1["dd-trace-java #11892<br/>default CDN source"] ST1["system-tests #7298<br/>no-Agent configuration harness"] ST2["system-tests #7299<br/>sidecar/direct routing contracts"] STM0["system-tests #7300<br/>enable Java configuration manifest"] JAVAS["Java side-effect implementation<br/>sidecar preferred"] JAVAD["Java side-effect implementation<br/>direct fallback"] STMS["Small manifest PRs<br/>enable Java side-effect rows"] JAVA1 --> STM0 ST1 --> STM0 ST1 --> ST2 ST2 --> JAVAS ST2 --> JAVAD JAVAS --> STMS JAVAD --> STMS classDef current fill:#fcbf49,stroke:#8a5a00,stroke-width:3px,color:#111; class ST2 current;Supported Architectures
Neither route contains a standalone Datadog Agent.
flowchart TB CDN1["Mocked CDN / UFC source"] --> SDK1["Server SDK"] SDK1 -->|"EVP: exposure + aggregate evaluation"| SIDECAR["Datadog serverless sidecar"] SDK1 -->|"OTLP: evaluation metrics"| SIDECAR SIDECAR --> SIDEINTAKE["Mocked Datadog intake<br/>interfaces.ffe_sidecar"] SDK1 -.->|assert no direct traffic| DIRECTTRIP["interfaces.ffe_direct<br/>must remain empty"] CDN2["Mocked CDN / UFC source"] --> SDK2["Server SDK"] SDK2 -->|"authenticated EVP + OTLP"| DIRECTINTAKE["Mocked Datadog intake<br/>interfaces.ffe_direct"] SDK2 -.->|assert no sidecar traffic| SIDETRIP["interfaces.ffe_sidecar<br/>must remain empty"] subgraph Preferred["Sidecar available: preferred route"] SDK1 SIDECAR SIDEINTAKE DIRECTTRIP end subgraph Fallback["No sidecar: direct fallback"] SDK2 DIRECTINTAKE SIDETRIP endChanges
datadog/serverless-initas the sidecar conduit and capture sidecar and direct intake on separate proxy ports/interfaces.interfaces.agent.missing_feature.Decisions
automeans prefer the local serverless sidecar and use authenticated direct intake only when the sidecar is unavailable.Validation
./format.sh --check: pass, including mypy, Ruff, YAML, manifest parsers, shellcheck, and Node checks.TEST_THE_TESTsuite: 48 passed.ff586da612, forced past the dormant manifests:/api/v2/exposures,/api/v2/flagevaluation, and/api/v2/series, with no direct-route capture.TEST_THE_TEST: 336 passed, 1 xfailed. Its only 2 failures are the pre-existing JUnit golden comparison embedding this worktree's absolute path instead of a checkout namedsystem-tests.Next Steps