Skip to content

Populate source.name and source.version on flag_evaluations and exposures EVP - #12200

Draft
vjfridge wants to merge 4 commits into
masterfrom
vickie/ffl-2995-sdk-name-and-version-java
Draft

Populate source.name and source.version on flag_evaluations and exposures EVP#12200
vjfridge wants to merge 4 commits into
masterfrom
vickie/ffl-2995-sdk-name-and-version-java

Conversation

@vjfridge

@vjfridge vjfridge commented Aug 12, 2026

Copy link
Copy Markdown
Contributor

Summary

The Java server SDK emits flag_evaluations and exposures EVP data via FeatureFlagEvpPublisher/api/v2/flagevaluation, but did not populate the SDK/tracer name or version on the payload. Grep of products/feature-flagging for source.name, source.version, telemetry.sdk.*, sdk.version returned zero matches.

Change

FeatureFlagEvpContext.from builds the top-level context map shared by both the flagevaluation and exposures EVP writers (FlagEvaluationWriterImpl and ExposureWriterImpl both call it). Add two keys:

  • source.name"dd-trace-java" (new SOURCE_NAME constant)
  • source.versionTracerVersion.TRACER_VERSION (existing build-time constant, read from the dd-java-agent.version resource — the same value the telemetry module sends as tracer_version on heartbeats)

Because the context map is shared, this single change populates the source.name / source.version facets on both EVP streams.

Prior art

TelemetryRequestBody (telemetry module) already sends tracer_version and language_name on every telemetry request. This reuses the same TracerVersion.TRACER_VERSION constant — no new version-lookup machinery.

Testing

  • ./gradlew :products:feature-flagging:feature-flagging-lib:test
  • ./gradlew :products:feature-flagging:feature-flagging-lib:spotlessCheck
  • Updated ExposureWriterTests.assertContext to assert source.name and source.version (referencing TracerVersion.TRACER_VERSION so the assertion is environment-agnostic).

Jira

Generated with Claude Code

…ures EVP

FeatureFlagEvpContext.from builds the top-level context map shared by both
the flagevaluation and exposures EVP writers. Add source.name ("dd-trace-java")
and source.version (TracerVersion.TRACER_VERSION) so the SDK identity facets
are populated on both EVP streams. This closes the gap noted in the Feature
Flag Observability Telemetry Roadmap where the Java server SDK emitted no
SDK/tracer name or version on the flag_evaluations EVP stream.

Co-Authored-By: Claude <noreply@anthropic.com>
@vjfridge vjfridge added tag: ai generated Largely based on code generated by an AI or LLM comp: openfeature OpenFeature comp: telemetry Telemetry type: feature Enhancements and improvements labels Aug 12, 2026
@datadog-datadog-prod-us1-2

This comment has been minimized.

@dd-octo-sts

dd-octo-sts Bot commented Aug 12, 2026

Copy link
Copy Markdown
Contributor

🟢 Java Benchmark SLOs — All performance SLOs passed

Suite Status
Startup 🟢 pass

SLO thresholds are defined here based on automatically generated metrics. A warning is raised when results are within 5% of the threshold.

PR vs. master results
Scenario Candidate master Δ (95% CI of mean)
startup:insecure-bank:iast:Agent 14.88 s 14.78 s [-0.3%; +1.6%] (no difference)
startup:insecure-bank:tracing:Agent 13.59 s 13.77 s [-2.0%; -0.5%] (maybe better)
startup:petclinic:appsec:Agent 17.56 s 17.33 s [+0.5%; +2.2%] (maybe worse)
startup:petclinic:iast:Agent 17.52 s 17.64 s [-1.4%; +0.1%] (no difference)
startup:petclinic:profiling:Agent 17.46 s 17.44 s [-0.9%; +1.2%] (no difference)
startup:petclinic:sca:Agent 17.45 s 17.20 s [+0.5%; +2.4%] (maybe worse)
startup:petclinic:tracing:Agent 16.14 s 16.70 s [-7.7%; +1.0%] (no difference)

Commit: 4aa5a6f9 · CI Pipeline · Benchmarking Platform UI


Load and DaCapo benchmarks can be triggered manually in the GitLab pipeline. Results will appear in the Benchmarking Platform UI after completion.

@PerfectSlayer PerfectSlayer removed the comp: telemetry Telemetry label Aug 13, 2026
vjfridge and others added 2 commits August 13, 2026 13:26
…ntext

The flagevaluation track schema (logs-backend flagevaluation.conf) declares
source.name/source.version as top-level per-event fields, siblings of
flag/variant/targeting_key. The previous implementation put them in the
batch context envelope alongside service/env/version, which the EVP indexer
maps to context.source.* — an undeclared facet that causes the indexer to
drop the entire event.

Move source to the FlagEvaluationEvent top level (as a nested source object
{name,version}) so it lands on the declared source.name/source.version
facets. Verified end-to-end via ffe-dogfooding against staging: Java
flagevaluation events now index in the staging flag_evaluations data source.

Generated with Claude Code

Co-Authored-By: Claude <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp: openfeature OpenFeature tag: ai generated Largely based on code generated by an AI or LLM type: feature Enhancements and improvements

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants