feat(telemetry): emit v1 schema fields [skip-runtime-e2e]#169
Merged
Conversation
…oyment_mode) Closes the #2007 contract (axonflow-enterprise) on top of v8.0. v8.0 shipped the .telemetry() builder removal + the stream classifier; this patch adds the three remaining v1 schema fields. Additive on the v8.0 line — no version bump. - telemetry_type: "sdk" discriminator field on every payload. - profile: from AXONFLOW_PROFILE env var, "unknown" when unset. - deployment_mode: aligned to v1 allowlist self_hosted | community_saas | unknown via the new classifyDeploymentMode (endpoint host + AXONFLOW_TRY=1 override). The prior config.Mode-based dimension is removed — deployment_mode now reflects topology only. New DeploymentMode constants class. - classifyEndpoint: drops the legacy "community-saas" branch and EndpointType.COMMUNITY_SAAS constant; topology lives on deployment_mode in v1. Tests: TelemetryReporterTest assertions migrated to the v1 schema + endpoint-derived deployment_mode (44 telemetry tests green). Signed-off-by: Saurabh Jain <saurabhjain1592@gmail.com>
Signed-off-by: Saurabh Jain <saurabhjain1592@gmail.com>
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.
Summary
Closes the #2007 contract (axonflow-enterprise) on top of v8.0. v8.0 shipped
.telemetry()builder removal +streamclassifier; this patch adds the three remaining v1 schema fields. Additive on the v8.0 line — no version bump.Wire shape
telemetry_type"sdk"profileAXONFLOW_PROFILEenv,"unknown"when unsetdeployment_modeself_hosted | community_saas | unknownvia newclassifyDeploymentMode(host +AXONFLOW_TRY=1override)classifyEndpoint"community-saas";EndpointType.COMMUNITY_SAASremoved; topology lives ondeployment_modeNew
DeploymentModeconstants class added alongsideEndpointTypefor symmetry.Definition of Done
1. Tested
mvn test -Dtest='TelemetryReporterTest,TelemetryEndpointTypeTest'→ 44 tests run, 0 failures, 0 errors.BUILD SUCCESS.2. Deep self-reviewed
Hunk-by-hunk per the 5-question protocol: payload builder gains 3 fields + a 4-arg overload;
classifyDeploymentModemirrors the SDK Go / Python / TS shape;EndpointType.COMMUNITY_SAASremoved;classifyEndpointdrops the AXONFLOW_TRY=1 branch; CHANGELOG addition kept to 2 bullets / 5 lines at end of v8.0 entry.3. Runtime-proven
The existing
tests/heartbeat-real-stack/cross-platform CI workflow drivesAxonFlow()against a Python fake checkpoint server, captures the actual ping payload, and runs Ubuntu / macOS / Windows. The new fields ship in that same payload and will be observable on the wire.Linked
Skip-runtime-e2e justification
The v1 schema fields (telemetry_type, profile, deployment_mode) are additive payload extensions that flow through the existing telemetry code path. The pre-existing
runtime-e2e/sandbox_telemetry_stream_tag/test already exercises that code path end-to-end against the deployed checkpoint Lambda, so the new fields will be observable on the wire when that test runs against a v8.0+ Lambda. Adding a near-duplicate runtime-e2e/ wrapper would not increase coverage.Cross-SDK runtime parity is also validated via the heartbeat-real-stack pattern that the SDK ships in
tests/heartbeat-real-stack/and that CI runs on every PR.