Component
API or orchestration, Agent (Python runtime), CDK / infrastructure
Describe the feature
Implement end-to-end task attribution and unified cross-plane trace correlation so every action in a task's lifecycle can be traced back to {task_id, user_id, repo} and a single shared trace root — across the orchestrator, agent runtime, GitHub/API calls, TaskEvents, OpenTelemetry spans, and S3 trace artifacts.
Today attribution is partial: per-session IAM scoping (#209, shipped) tags tenant-data access; git commits carry Task-Id trailers; TaskEvents and task records hold operational fields. Gaps remain in orchestrator structured logs, agent OTel baggage propagation, external API call correlation, and stitching MicroVM traces to platform-side events for incident response.
This issue is the platform identity contract — distinct from Bedrock billing attribution (#215) and compliance export schema (#237), though all three should share the same correlation field names.
Use case
Proposed solution
Phase 0 — Correlation contract
- Document a stable correlation envelope:
{ task_id, user_id, repo, trace_id, session_id? } and where each field is authoritative.
- Define naming consistency across orchestrator logs, agent OTel resource/span attributes,
TaskEvents optional fields, and git/API metadata.
Phase 1 — Propagation MVP
- Orchestrator: inject correlation into structured logs and durable-step context for every task transition.
- Agent: propagate envelope via OTel baggage / span attributes from session start through pipeline phases and progress events.
- Ensure
progress_writer and terminal events include correlation stamps where missing.
Phase 2 — Cross-plane trace root
- Single trace root per task linking orchestrator spans, MicroVM agent spans, and (where available) S3 trace artifact URI.
- Gap-fill beyond existing AgentCore session baggage (
OBSERVABILITY.md); align with bgagent trace download artifact paths.
Phase 3 — Downstream attribution (follow-up OK in same issue or child)
- GitHub commits/PR comments: consistent actor + task metadata (extend existing trailers).
- External webhook/API calls from handlers: correlation headers or structured log fields.
Out of scope for initial delivery
Acceptance criteria
Other information
Acknowledgements
Component
API or orchestration, Agent (Python runtime), CDK / infrastructure
Describe the feature
Implement end-to-end task attribution and unified cross-plane trace correlation so every action in a task's lifecycle can be traced back to
{task_id, user_id, repo}and a single shared trace root — across the orchestrator, agent runtime, GitHub/API calls,TaskEvents, OpenTelemetry spans, and S3 trace artifacts.Today attribution is partial: per-session IAM scoping (#209, shipped) tags tenant-data access; git commits carry
Task-Idtrailers;TaskEventsand task records hold operational fields. Gaps remain in orchestrator structured logs, agent OTel baggage propagation, external API call correlation, and stitching MicroVM traces to platform-side events for incident response.This issue is the platform identity contract — distinct from Bedrock billing attribution (#215) and compliance export schema (#237), though all three should share the same correlation field names.
Use case
abca.audit.v1correlationblock from real propagated context, not ad-hoc assembly.trace_id/task_id.Proposed solution
Phase 0 — Correlation contract
{ task_id, user_id, repo, trace_id, session_id? }and where each field is authoritative.TaskEventsoptional fields, and git/API metadata.Phase 1 — Propagation MVP
progress_writerand terminal events include correlation stamps where missing.Phase 2 — Cross-plane trace root
OBSERVABILITY.md); align withbgagent trace downloadartifact paths.Phase 3 — Downstream attribution (follow-up OK in same issue or child)
Out of scope for initial delivery
user_id → orchestrator → agentchain) — separate follow-up once basic propagation is stable.cost_usdor FinOps dashboards (feat: Bedrock cost attribution — session tags, request metadata, and operator FinOps guidance #215, RFC: Governance planes — analytics and compliance export #237).Acceptance criteria
{ task_id, user_id, repo, trace_id }present in orchestrator structured logs for admission → terminal transitions.TaskEventswritten during a run are joinable to orchestrator logs and trace artifacts bytask_idandtrace_id.Other information
docs/guides/ROADMAP.md).Acknowledgements