From 315b3ea4810809d437061120567de6ae5ab82c9c Mon Sep 17 00:00:00 2001 From: Juliano Costa Date: Tue, 5 Sep 2023 08:00:38 +0200 Subject: [PATCH] Fix TraceTest after IBM/sarama upgrade (#1096) * Fix TraceTest after IBM/sarama upgrade * changelog --- CHANGELOG.md | 2 ++ test/tracetesting/checkout-service/place-order.yaml | 4 ++-- .../tracetesting/frontend-service/06-checking-out-cart.yaml | 6 +++--- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2228859bbd..c75897a9ec 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -85,6 +85,8 @@ release. ([#1085](https://github.com/open-telemetry/opentelemetry-demo/pull/1085)) * [cartservice] Support for logs ([#1086](https://github.com/open-telemetry/opentelemetry-demo/pull/1086)) +* [TraceTests] Update span attributes to align with new IBM/sarama instrumentation + ([#1096](https://github.com/open-telemetry/opentelemetry-demo/pull/1096)) ## 1.4.0 diff --git a/test/tracetesting/checkout-service/place-order.yaml b/test/tracetesting/checkout-service/place-order.yaml index 800ef158d6..6334fc883a 100644 --- a/test/tracetesting/checkout-service/place-order.yaml +++ b/test/tracetesting/checkout-service/place-order.yaml @@ -45,6 +45,6 @@ spec: assertions: - attr:rpc.grpc.status_code = 0 - name: It sends an order to be processed asyncronously - selector: span[tracetest.span.type="messaging" name="orders send" messaging.system="kafka" messaging.destination="orders" messaging.destination_kind="topic" messaging.operation="send"] + selector: span[tracetest.span.type="messaging" name="orders publish" messaging.system="kafka" messaging.destination.name="orders" messaging.destination.kind="topic" messaging.operation="publish"] assertions: - - attr:messaging.destination = "orders" + - attr:messaging.destination.name = "orders" diff --git a/test/tracetesting/frontend-service/06-checking-out-cart.yaml b/test/tracetesting/frontend-service/06-checking-out-cart.yaml index db54d7ab41..d3bf1cb043 100644 --- a/test/tracetesting/frontend-service/06-checking-out-cart.yaml +++ b/test/tracetesting/frontend-service/06-checking-out-cart.yaml @@ -59,12 +59,12 @@ spec: - attr:rpc.grpc.status_code = 0 - attr:tracetest.selected_spans.count >= 1 - name: The order was sent to be processed asyncronously - selector: span[tracetest.span.type="messaging" name="orders send" messaging.system="kafka" messaging.destination="orders" messaging.destination_kind="topic" messaging.operation="send"] + selector: span[tracetest.span.type="messaging" name="orders publish" messaging.system="kafka" messaging.destination.name="orders" messaging.destination.kind="topic" messaging.operation="publish"] assertions: - - attr:messaging.destination = "orders" + - attr:messaging.destination.name = "orders" - name: The order was sent to accountability # captures the span emitted by Kafka instrumentation for Go - selector: span[tracetest.span.type="messaging" name="orders receive" messaging.system="kafka" messaging.destination="orders" messaging.destination_kind="topic" messaging.operation="receive"] + selector: span[tracetest.span.type="messaging" name="orders receive" messaging.system="kafka" messaging.destination.name="orders" messaging.destination.kind="topic" messaging.operation="receive"] assertions: - attr:name = "orders receive" - name: The order was sent to fraud detection team