Repository navigation
feat(openfeature): add shared agentless EVP fallback - #6574
leoromanovsky wants to merge 7 commits into
Conversation
Typing analysisNote: Ignored files are excluded from the next sections. Untyped methodsThis PR introduces 7 partially typed methods. It increases the percentage of typed methods from 73.41% to 73.47% (+0.06%). Partially typed methods (+7-0)❌ Introduced:Untyped other declarationsThis PR introduces 1 partially typed other declaration. It increases the percentage of typed other declarations from 87.0% to 87.09% (+0.09%). Partially typed other declarations (+1-0)❌ Introduced:If you believe a method or an attribute is rightfully untyped or partially typed, you can add |
❌ ErrorsYour PR has failed checks. Please review the issues below and take necessary action before merging. 🚦 2 Pipeline jobs failed
ℹ️ InfoNo other issues found (see more)🧪 All tests passed 🎯 Code Coverage (details) Useful? React with 👍 / 👎 This comment will be updated automatically if new data arrives.🔗 Commit SHA: 040f61a | Docs | View more details | Give us feedback! |
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.
An empty HTTPS proxy environment variable causes direct exposure and flag-evaluation batches to be dropped. The localized suggestion handles empty values while preserving configured proxies and no_proxy exclusions.
🤖 Bits Code Review · Commit ff41edc
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: ff41edc95f
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Preserve bounded delivery shutdown, fork isolation, and shared transport construction alongside the new Feature Flags diagnostics. Replace the timed shutdown test sleep with deterministic synchronization.
buraizu
left a comment
There was a problem hiding this comment.
Thanks for the PR! I've posted a few edit requests for the new docs content, but let me know if you have any questions or feedback.
Address review feedback with user-focused delivery guidance, precise fallback and reconfiguration behavior, and clearer release wording. Environment: Datadog workspace
FFE reviewer selectionReviewers: @vjfridge, @sameerank Why: Agentless and serverless delivery — The PR adds a shared agentless event transport. Reviewers come from the matched pod. 🤖 Automated selection. Selection detailsInitiative: project / deployment-modes Why this match: The PR adds a shared agentless event transport. It discovers a local EVP endpoint and falls back to direct HTTPS intake, so exposure and flag-evaluation events reach Datadog without a persistent Agent. This is the evaluation/exposure event egress that deployment-modes covers. The component wires this transport into both writers when the configuration source is agentless. The shutdown changes bound the agentless delivery deadlines and drain the writers. They are part of that delivery path and do not change OpenFeature provider lifecycle or evaluation metadata contracts, so the openfeature-architecture area is not added.
The PR author was excluded. Existing reviewers and teams were preserved. Debug or fix a problemWorkflow run · Bits Code session
Evidence and run details✅ Complete — reviewer coverage verified. The workflow checked pending requests or submitted reviews on the evaluated head. Generated asynchronously by the FFE reviewer-routing workflow. Changed paths: Evaluated head: Registry revision: Pinned skill source: Instructions: workflow-injected snapshot (no plugin loaded) Instruction snapshot SHA-256: |
Preserve older-Agent delivery without direct credentials, decode proxy and configuration URL credentials across supported URI versions, and warn when no event route is available. Start evaluation shutdown before waiting for exposures and use five-second discovery and delivery budgets. Add deterministic regressions and clarify Agent and proxy requirements. Environment: Datadog workspace
Why
Ruby applications using agentless Feature Flags configuration still depend on a local Agent to deliver exposures and flag evaluations. These signals need to reach Datadog when that receiver is unavailable.
What
Both writers share local EVP discovery and sticky HTTPS intake fallback, while Remote Configuration retains its existing transport. Current batches replay only after 404/405 or proven pre-transmission failures; ambiguous failures and 403/429/5xx switch future batches only.
Risk
Reverting before release restores Agent-only delivery and the previous writer lifecycle. Direct intake refuses redirects and keeps API keys direct-only; shutdown changes also affect Remote Configuration, rejecting late evaluations and limiting exposure joins to three seconds, so undelivered events can be dropped.
Details
Delivery and shutdown decisions
Discovery prefers an Agent or relay that forwards EVP origin metadata, then authenticated direct intake. When direct delivery is not configured, the library can still send through an older Agent's advertised EVP endpoint. Discovery and requests each allow five seconds, clipped to the remaining agentless shutdown deadline; this is not a five-second bound on the entire component shutdown.
The component signals the flag-evaluation writer to flush before waiting for exposure shutdown. Exposure shutdown allows up to one additional second for forced termination. The shared transport deadline applies only to agentless delivery; the writer lifecycle changes also affect Remote Configuration.
The configured Agent URL path prefix remains supported for local discovery and event delivery when its endpoint matches the resolved Agent settings. Traces and Remote Configuration retain their existing fixed paths.
Cross-SDK references
Java's earlier delivery implementation was removed by #12844; the open #12978 restores delivery through the SDK bridge. Merged .NET #9351 applies fallback to flag evaluations as well as exposures, with independent transport instances for each signal. Ruby deliberately shares one component-owned selector so both writers reuse discovery and subsequent fallback decisions.
Validation and limits
Native OpenFeature suites pass on Ruby 3.1 minimum/latest (1082/1082 examples) and Ruby 4.0 minimum/latest (1082/1086 examples), with zero failures. Changed-file RuboCop passes. Full Steep passes.
Nine mutation controls detect restored defects in older-Agent fallback, URI compatibility, warning emission and suppression, shutdown overlap and late events, discovery serialization, untraced headers, and empty proxy hostnames. A synthetic TCP receiver taking 2.25 seconds fails under the previous one-/two-second limits and succeeds under five seconds. An actual URI 0.12.2 probe verifies credential decoding for event proxies and custom configuration URLs.
The earlier system-test receipt targets
ff41edc95fd4ea4fa59bd4793a6bfe5c76d923e1; it was not rerun for this update. Native and synthetic checks do not establish production intake or deployment readiness.