From d9ee004b45e35e833917a3b5aa18f5484c832417 Mon Sep 17 00:00:00 2001 From: kkeirstead <85592574+kkeirstead@users.noreply.github.com> Date: Tue, 17 Oct 2023 13:59:18 -0700 Subject: [PATCH] [Dotnet Monitor] Small Fix For SDM Triggers (#4332) Small bug fix on the dotnet-monitor side from the unification work - we previously didn't create a payload for `BeginInstrumentReporting`, and thus only checked that a payload wasn't an error or the end of a counter. The code now leverages the newly-added `IsValuePublishedEvent` from the unification to only apply to the correct payloads. --- .../SystemDiagnosticsMetricsTriggerImpl.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Microsoft.Diagnostics.Monitoring.EventPipe/Triggers/SystemDiagnosticsMetricsTrigger/SystemDiagnosticsMetricsTriggerImpl.cs b/src/Microsoft.Diagnostics.Monitoring.EventPipe/Triggers/SystemDiagnosticsMetricsTrigger/SystemDiagnosticsMetricsTriggerImpl.cs index d0e4e2808..c10d87f1a 100644 --- a/src/Microsoft.Diagnostics.Monitoring.EventPipe/Triggers/SystemDiagnosticsMetricsTrigger/SystemDiagnosticsMetricsTriggerImpl.cs +++ b/src/Microsoft.Diagnostics.Monitoring.EventPipe/Triggers/SystemDiagnosticsMetricsTrigger/SystemDiagnosticsMetricsTriggerImpl.cs @@ -55,7 +55,7 @@ namespace Microsoft.Diagnostics.Monitoring.EventPipe.Triggers.SystemDiagnosticsM { EventType eventType = payload.EventType; - if (eventType.IsError() || eventType == EventType.CounterEnded) + if (!eventType.IsValuePublishedEvent()) { // not currently logging the error messages -- 2.34.1