2 writes to Duration
System.Diagnostics.DiagnosticSource (2)
System\Diagnostics\Activity.cs (2)
767
Duration
= endTimeUtc - StartTimeUtc;
769
Duration
= new TimeSpan(1); // We want Duration of 0 to mean 'EndTime not set)
9 references to Duration
Aspire.StackExchange.Redis (1)
src\Vendoring\OpenTelemetry.Instrumentation.StackExchangeRedis\StackExchangeRedisConnectionInstrumentation.cs (1)
115
if (parent.
Duration
== TimeSpan.Zero)
Microsoft.AspNetCore.Hosting (1)
Internal\HostingApplicationDiagnostics.cs (1)
475
if (activity.
Duration
== TimeSpan.Zero)
Microsoft.AspNetCore.Hosting.Tests (2)
HostingApplicationDiagnosticsTests.cs (2)
640
Assert.True(Activity.Current.
Duration
> TimeSpan.Zero);
664
Assert.True(Activity.Current.
Duration
> TimeSpan.Zero);
System.Diagnostics.DiagnosticSource (5)
System\Diagnostics\Activity.cs (4)
753
/// Update the Activity to set <see cref="
Duration
"/>
768
if (
Duration
.Ticks <= 0)
843
/// If end time was not set previously, sets <see cref="
Duration
"/> as a difference between <see cref="DateTime.UtcNow"/> and <see cref="StartTimeUtc"/>
860
if (
Duration
== TimeSpan.Zero)
System\Diagnostics\DiagnosticSourceActivity.cs (1)
57
if (activity.
Duration
== TimeSpan.Zero)