CJM-119729: AJO Custom Channels execution metrics XDM mixin (Phase 1)#2181
Open
mukullamba04 wants to merge 1 commit into
Open
CJM-119729: AJO Custom Channels execution metrics XDM mixin (Phase 1)#2181mukullamba04 wants to merge 1 commit into
mukullamba04 wants to merge 1 commit into
Conversation
Adds two extensions/ schemas: - custom-channel-execution-metrics: per-call HTTP execution detail emitted on message.feedback for custom-channel sends - (Integration mixin deferred to Phase 1B - design preserved in internal wiki, not shipped in this PR) Field design (custom-channel-execution-metrics): endpoint (URL template form, placeholders un-substituted), method, requestTimestamp, responseTime (ms), waitTime (ms, Phase-2 reserved), statusCode (raw HTTP int), throttleApplicable (config-applied flag), errorCode (free-form string), errorReason. errorCode kept as free-form string in XDM (no enum constraint) to let producers evolve the controlled vocabulary without an XDM schema update. URL-template form chosen for the endpoint field to avoid per-recipient cardinality explosion in downstream live reporting; precedent is the email domain-derived field that truncates link URLs. Examples: success (200) + HTTP 503 covering populated + error cases.
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
Adds the
custom-channel-execution-metricsXDM field group underextensions/adobe/experience/customerJourneyManagement/, capturing per-call HTTP execution detail for AJO Custom Channels sends. This is the schema half of the broader AJO Custom Channels Monitoring (Phase 1) epic — paired with the Scala model in Adobe-CJM/message-runtime#5952 (now reopened) and the producer wiring in Adobe-CJM/message-streaming-worker#91, feeding the CJA template skeleton in AdobeAnalytics/aaui-features#392 (now reopened). Design source-of-truth: internal wiki 3886615741.Key contracts / behaviors
Field design (
custom-channel-execution-metrics)endpoint: URL template form — placeholders ({{profile.email}}, etc.) are un-substituted before emit. This is the deliberate cardinality control; the email channel uses the same pattern (domain-only, link URL truncated) to avoid blowing up downstream live-reporting dimensions per-recipient.method: HTTP verb, raw string.requestTimestamp: ISO-8601, set when the HTTP boundary is crossed.responseTime: integer ms, measured around the HTTP boundary only (auth lookup excluded).waitTime: integer ms, Phase-2 reserved — emitted as 0 today, will be wired when throttling buckets / pre-call queuing are exposed.statusCode: raw integer HTTP status code (no enum, no remapping).throttleApplicable: boolean — true if a throttling config was applied to this call (not whether it was throttled). Lets downstream split capped vs. uncapped populations.errorCode: free-form string. Kept as a string in XDM (NO enum constraint) — controlled vocabulary lives in the producer (message-runtime/ExecutionErrorCode, 9 codes today:AUTH_CACHE_IO,AUTH_HTTP_ERROR,AUTH_TOKEN_PARSE,AUTH_TOKEN_EXPIRED,REQUEST_GENERATION_ERROR,HTTP_4XX,HTTP_5XX,HTTP_TIMEOUT,HTTP_PARSE_ERROR). Producers can extend the vocabulary without an XDM schema change.errorReason: free-form human-readable string, no PII contract beyond the existing event-level redaction.Integration mixin — deferred
The companion
integration-execution-metricsmixin that originally lived alongside this one has been removed from Phase 1 scope. Design is preserved in the wiki and will land in Phase 1B. Only the custom-channel mixin ships here.Flow (Mermaid)
sequenceDiagram autonumber participant Cfg as ApiIntegrationSettings participant MSW as message-streaming-worker participant Exec as APIIntegrationExecutor participant FB as message.feedback emitter participant XDM as XDM field group<br/>(custom-channel-execution-metrics) Cfg->>MSW: endpoint template (un-interpolated) MSW->>Exec: executeWithMetadata(req) Exec-->>MSW: APIIntegrationExecutionMetadata<br/>(statusCode, responseTime) MSW->>FB: build feedback event<br/>endpoint = template<br/>statusCode = raw<br/>errorCode = ExecutionErrorCode.value FB->>XDM: emit message.feedbackObservability
message.feedback→ live-reporting-ingestion-adapter → live-reporting-service → CJA Workspace.Schema / Repo keys
extensions/adobe/experience/customerJourneyManagement/custom-channel-execution-metrics.schema.jsonextensions/adobe/experience/customerJourneyManagement/custom-channel-execution-metrics.example.1.json(success / 200)extensions/adobe/experience/customerJourneyManagement/custom-channel-execution-metrics.example.2.json(HTTP 503 / populated error)Deployment / rollout notes
message-runtime,message-streaming-worker,live-reporting-*,metrics-registry-deploy, andaaui-featuresall reference field names defined here. Merge order: this → message-runtime → message-streaming-worker → live-reporting → metrics-registry → aaui.Testing
XDM repo CI validates schema/example consistency; the two examples cover the populated-success (HTTP 200) and populated-error (HTTP 503) cases. Producer/consumer integration is covered in the linked PRs.
Related work (this Phase-1 stack)