Skip to content
This repository was archived by the owner on Aug 5, 2026. It is now read-only.

cdc traces: SetupTracing + cross-composition propagation + digest exclusion (KOS-1 Phase 2+3) - #12

Merged
braghettos merged 2 commits into
mainfrom
kos1-phase2-3-cdc-tracing
Jun 22, 2026
Merged

cdc traces: SetupTracing + cross-composition propagation + digest exclusion (KOS-1 Phase 2+3)#12
braghettos merged 2 commits into
mainfrom
kos1-phase2-3-cdc-tracing

Conversation

@braghettos

Copy link
Copy Markdown
Collaborator

cdc traces: SetupTracing + cross-composition propagation + digest exclusion (KOS-1 Phase 2+3)

Part of braghettos/krateo-installer#112 — step ③. Wires unstructured-runtime v1.3.0's trace pipeline + plumbing v1.7.7's traceparent stamping into cdc.

Changes

  • go.mod: repin unstructured-runtime v1.3.0 + plumbing v1.7.7 (the v1.7.x line — the v1.8.x fork dropped slogs/pretty the chain needs).
  • main.go: OTEL_TRACING_ENABLED flag + telemetry.SetupTracing (gated, default-off). Clean-schema identity: service.version from SERVICE_VERSION env; watched type as krateo.io/composition-gvr (via OTEL_RESOURCE_ATTRIBUTES); krateo.io/composition-id stays the per-instance UID.
  • composition.go: stamp the active reconcile trace onto child manifests (InjectTraceparentpostRender.WithTraceparent) at Observe + Create → child compositions continue the same distributed trace.
  • processor.go: exclude krateo.io/traceparent/tracestate from ComputeReleaseDigest — else the per-reconcile trace value churns a helm Upgrade every reconcile. Fast-path keeps traceparent-free manifests hashing as before. Test proves two manifests differing only in traceparent hash identically.

Validated

go build/vet/test green. Default-off → byte-identical until enabled. On tag, the image builds + auto-PRs core-provider-chart cdc.image.tag.

🤖 Generated with Claude Code

braghettos and others added 2 commits June 22, 2026 15:24
…ase 2+3)

Pull the tracing-capable lib (v1.3.0: metrics resource attrs + SetupTracing + reconcile
span) and the traceparent-stamping post-renderer (plumbing v1.7.7, the v1.7.x maintenance
line that retains slogs/pretty -- the divergent v1.8.x line dropped it). Build/vet green;
inert until the SetupTracing wiring + composition.go inject land (next).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…st exclusion (KOS-1 Phase 2+3)

Wire the v1.3.0 lib's trace pipeline into cdc:
- main.go: OTEL_TRACING_ENABLED flag + telemetry.SetupTracing (gated, default off); service.version
  from SERVICE_VERSION env; the watched type as krateo.io/composition-gvr via OTEL_RESOURCE_ATTRIBUTES
  (clean schema -- composition-id stays the per-instance UID).
- composition.go: stamp the active reconcile trace onto child manifests (InjectTraceparent ->
  postRender.WithTraceparent) at Observe + Create, so child compositions continue the trace.
- processor.go: EXCLUDE krateo.io/traceparent (+ tracestate) from ComputeReleaseDigest, so the
  per-reconcile trace value never triggers a spurious helm Upgrade (churn-safety). Test proves
  two manifests differing only in traceparent hash identically.

Build/vet/tests green. Default-off => byte-identical behavior until enabled.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@braghettos
braghettos merged commit ff323cc into main Jun 22, 2026
3 checks passed
@braghettos
braghettos deleted the kos1-phase2-3-cdc-tracing branch June 22, 2026 15:14
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant