From 6ba75d8b72e721ddbe50ac87f80f6edcbf122787 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sim=C3=A3o=20Ribeiro?= Date: Thu, 9 Nov 2023 10:39:45 +0000 Subject: [PATCH] test: comment activity.complete --- .../Properties/launchSettings.json | 12 ++++++++++++ .../OpenTelemetryConsumerEventsHandler.cs | 2 +- .../OpenTelemetryProducerEventsHandler.cs | 2 +- 3 files changed, 14 insertions(+), 2 deletions(-) create mode 100644 src/KafkaFlow.Admin.Dashboard/Properties/launchSettings.json diff --git a/src/KafkaFlow.Admin.Dashboard/Properties/launchSettings.json b/src/KafkaFlow.Admin.Dashboard/Properties/launchSettings.json new file mode 100644 index 000000000..3557dbeb5 --- /dev/null +++ b/src/KafkaFlow.Admin.Dashboard/Properties/launchSettings.json @@ -0,0 +1,12 @@ +{ + "profiles": { + "KafkaFlow.Admin.Dashboard": { + "commandName": "Project", + "launchBrowser": true, + "environmentVariables": { + "ASPNETCORE_ENVIRONMENT": "Development" + }, + "applicationUrl": "https://localhost:58936;http://localhost:58937" + } + } +} \ No newline at end of file diff --git a/src/KafkaFlow.OpenTelemetry/OpenTelemetryConsumerEventsHandler.cs b/src/KafkaFlow.OpenTelemetry/OpenTelemetryConsumerEventsHandler.cs index 10fa794e9..f19c2a817 100644 --- a/src/KafkaFlow.OpenTelemetry/OpenTelemetryConsumerEventsHandler.cs +++ b/src/KafkaFlow.OpenTelemetry/OpenTelemetryConsumerEventsHandler.cs @@ -57,7 +57,7 @@ public static Task OnConsumeCompleted(IMessageContext context) { if (context.Items.TryGetValue(ActivitySourceAccessor.ActivityString, out var value) && value is Activity activity) { - activity?.Dispose(); + activity?.Stop(); } return Task.CompletedTask; diff --git a/src/KafkaFlow.OpenTelemetry/OpenTelemetryProducerEventsHandler.cs b/src/KafkaFlow.OpenTelemetry/OpenTelemetryProducerEventsHandler.cs index 3630157c1..4049e6d1d 100644 --- a/src/KafkaFlow.OpenTelemetry/OpenTelemetryProducerEventsHandler.cs +++ b/src/KafkaFlow.OpenTelemetry/OpenTelemetryProducerEventsHandler.cs @@ -67,7 +67,7 @@ public static Task OnProducerCompleted(IMessageContext context) { if (context.Items.TryGetValue(ActivitySourceAccessor.ActivityString, out var value) && value is Activity activity) { - activity?.Dispose(); + activity?.Stop(); } return Task.CompletedTask;