Skip to content

feat(tracing): mark invocation spans as ERA roots - #1195

Merged
yaozheng-fang merged 2 commits into
volcengine:mainfrom
feng-95:feat/invocation-root-span-type
Nov 2, 2026
Merged

yaozheng-fang merged 2 commits into
volcengine:mainfrom
feng-95:feat/invocation-root-span-type

Conversation

@feng-95

@feng-95 feng-95 commented Nov 2, 2026 •

Copy link
Copy Markdown
Contributor

VeADK invocation spans now receive era.span_type="root" when they start, so APMPlus can identify the invocation entrypoint before a model response is available. The marker is retained through cloud export even when local span retention is disabled. Agent and LLM child spans remain unmarked.

This is an additive telemetry attribute on the existing invocation-name branch, including invocations with an upstream parent. It does not change public Python signatures, configuration, or span parentage. The schema-v2 invoke_workflow entrypoint is outside this change.

Validation on 2026-11-02, against base 65f30f28 and the final two-file runtime/test diff:

  • pass: the new regression assertions failed before implementation and passed afterward, covering the attribute at span creation, retention through cloud export, child-span exclusion, and enabled/disabled local retention.
  • pass: uv run --locked --extra dev --extra codex pytest tests/test_tracing.py tests/test_tracing_content.py tests/test_model_timing.py tests/config/test_tracing_config.py -q — 89 tests.
  • pass: uv run --locked --extra dev --extra codex pre-commit run --all-files — Ruff, formatting, secret scans, and dependency policy.
  • pass, live: a local Agent/Runner request to a real model produced four spans, the real APMPlus OTLP exporter returned success, and an APMPlus span query confirmed era.span_type=root on invocation with no marker on the three child spans. The smoke used synthetic user/session identifiers and disabled content collection. Credentials and cloud evidence are kept out of this PR.
  • pass: git diff --check.
  • fail, baseline/environment: uv run --locked --extra dev pytest -n 2 -m "not codex_smoke and not piagent_smoke" — 7,913 passed, 17 failed, 63 skipped, 4 xfailed. Rerunning those 17 tests from an isolated working directory with the codex extra installed yielded 15 passed and 2 failed. Both remaining failures reproduce on an unmodified archive of 65f30f28: platform .md MIME detection and a machine-global Git ignore rule affecting the sandbox-upload test fixture. No global configuration or test expectations were changed to bypass these failures.

The full regression suite is therefore not claimed to pass. Live verification covers the default ADK invocation path; external runtime smoke tests were not run.

@yaozheng-fang
yaozheng-fang merged commit 008a5cd into volcengine:main Nov 2, 2026
9 of 10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants