Repository navigation
chore(dev): add multiservice opentelemetry trace e2e test #26554
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
tessneau
wants to merge
29
commits into
master
Choose a base branch
from
tess.neau-real-trace-testing
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+2,228
−84
Open
Changes from 6 commits
Commits
Show all changes
29 commits
Select commit
Hold shift + click to select a range
f3ad538
Add manual OTel Demo trace E2E validation
tessneau f002f26
Clarify OTel trace test documentation and add architecture diagram
tessneau 6cb87b3
Rename OTel trace E2E suite to multiservice traces
tessneau f0aa5ba
Use cart failure flag for multiservice trace errors
tessneau d3d0e8b
Allow more time for multiservice trace workload in CI
tessneau 69aeb3a
chore: merge master into multiservice trace tests
tessneau bbecc34
test(opentelemetry): shorten multiservice trace workload runtime
tessneau d67df6e
fix(tests): fail quote readiness check on refused connections
tessneau 300e901
fix(tests): exit multiservice workload promptly and capture container…
tessneau f78f444
fix(tests): increase multiservice demo memory limits
tessneau 6cf6484
chore(vdev): add opt-in build cache preservation
tessneau 436d0c7
chore(merge): merge latest master
tessneau eb47200
test(opentelemetry): address trace e2e review feedback
tessneau ee670b2
test(opentelemetry): clarify workload completion dependency
tessneau 417d7cc
fix(vdev): preserve build artifacts during test cleanup
tessneau e9ed31a
fix(ci): build vdev from source for harness changes
tessneau d4dc6bf
docs(tests): replace trace architecture image with mermaid
tessneau c12b304
test(opentelemetry): use typed multiservice trace coverage
tessneau e40ab50
fix(tests): wait for metrics before e2e validation
tessneau 6a09618
refactor(tests): construct trace coverage through its type
tessneau acaf182
docs(tests): clarify the multiservice trace diagram
tessneau d00c5d8
refactor(tests): finalize trace captures before validation
tessneau 49759a1
fix(ci): build candidate vdev in merge queue and manual runs
tessneau 8750b01
chore(dev): merge shared compose harness fixes
tessneau 1ee47be
refactor(tests): use shared compose harness fixes
tessneau 72bfca4
fix(tests): drain vector before freezing trace captures
tessneau 30092e4
fix(tests): keep finalized trace environment active
tessneau 295b512
chore(dev): merge master after shared e2e fixes
tessneau 1a9cdf2
chore(dev): remove temporary trace e2e harness setup
tessneau File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,85 @@ | ||
| # Multiservice OpenTelemetry trace validation | ||
|
|
||
| This manual E2E test checks that Vector preserves multilingual, multiservice | ||
| traces from the | ||
| [OpenTelemetry Demo 3.1.0](https://github.com/open-telemetry/opentelemetry-demo/tree/3.1.0) | ||
| using the existing `vdev` Compose harness and | ||
| [OTel Collector](https://opentelemetry.io/docs/collector/) 0.159.0. | ||
|
|
||
| It provides realistic trace-preservation evidence for changes such as the | ||
| [trace model RFC](../../../rfcs/2026-04-29-25329-trace-data-model.md). | ||
| It runs manually because the full application setup is heavier than the | ||
| fixture-based trace tests. | ||
|
|
||
| ## Input and destination | ||
|
|
||
|  | ||
|
|
||
| Trace and span counts in the diagram are examples from local runs, not assertions. | ||
|
|
||
| [scenario.py](data/scenario.py) runs one simulated shopper through three rounds of ad, | ||
| recommendation, cart, and multi-item checkout requests. Checkout also exercises | ||
| the Kafka accounting and fraud-detection consumers. | ||
|
|
||
| [demo.flagd.json](data/demo.flagd.json) uses the Demo's default flags except | ||
| `cartFailure: 100%`. This generates cart-emptying error spans while checkout | ||
| continues to email and Kafka. | ||
|
|
||
| The [ingress Collector](data/collector-source.yaml) writes `input.jsonl` and | ||
| forwards traces to Vector. The [matrix](config/test.yaml) runs each transport | ||
| separately with the same checks: | ||
|
|
||
| - HTTP (`otlphttp`): `http://vector:4318/v1/traces`. | ||
| - gRPC (`otlp`): `vector:4317`. | ||
|
|
||
| Application logs and metrics are not forwarded to Vector. | ||
|
|
||
| Vector runs [data/vector.yaml](data/vector.yaml), mounted as | ||
| `/etc/vector/vector.yaml`: an `opentelemetry` source with | ||
| `use_otlp_decoding: true` feeds `otel.traces` directly to an `opentelemetry` | ||
| sink, which sends OTLP/HTTP to `http://otel-collector-sink:4318/v1/traces`. | ||
|
|
||
| The destination is a [second local Collector](data/collector-sink.yaml) that | ||
| writes `output.jsonl`. | ||
|
|
||
| ## Validations | ||
|
|
||
| The [Rust test](../opentelemetry/multiservice_traces/mod.rs) verifies: | ||
|
|
||
| - Completion: requires the workload marker, allows Kafka consumers to finish, | ||
| stops the input, and waits up to 120 seconds for Vector to drain. | ||
| - Service coverage: requires spans from 14 services exercised by the workload. | ||
| - Trace shapes: requires roots, multi-span traces, children with captured | ||
| parents, cross-service parent relationships, and error spans. | ||
| - Preservation: compares every span and its resource, scope, and schema URLs. | ||
| Missing, extra, or changed spans and duplicate counts fail. Only batching, | ||
| span order, and attribute-map order may differ. | ||
| - Capture format: fails on malformed IDs or unknown capture fields. | ||
|
|
||
| ## Coverage and limitations | ||
|
|
||
| - Decoding: only `use_otlp_decoding: true` is tested. | ||
| - Optional coverage: events, links, and scope groups with multiple trace IDs | ||
| are reported in `coverage.json` and compared when present. They are not required, | ||
| so a run without them can pass. | ||
| - Edge cases: the workload does not guarantee all field values, such as byte | ||
| attributes, missing scopes, or nonzero dropped counts. | ||
|
|
||
| ## Running and results | ||
|
|
||
| With Docker available, run both transports: | ||
|
|
||
| ```shell | ||
| cargo vdev e2e run opentelemetry-traces-multiservice --retries 0 --always-show-logs | ||
| ``` | ||
|
|
||
| To run one transport, add `-e 0.159.0-otlphttp` (HTTP) or `-e 0.159.0-otlp` (gRPC). | ||
|
|
||
| In CI, a Vector-team member can submit a PR review starting with | ||
| `/ci-run-e2e-opentelemetry-traces-multiservice` to test the reviewed commit. | ||
| Comments, “run all” commands, automatic PR CI, and schedules do not trigger it. | ||
|
|
||
| Read the results on the CI job's summary page. Download the | ||
| `otel-traces-multiservice-<commit>` artifact for input/output captures, `coverage.json`, | ||
| `differences.txt`, configs, and runner logs. Results are separated by transport; | ||
| failed runs may leave partial results. |
|
bruceg marked this conversation as resolved.
Outdated
|
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.