|
set |
|
{ |
|
this.enableW3c = value; |
|
ActivityExtensions.TryRun(() => |
|
{ |
|
if (this.enableW3c) |
|
{ |
|
Activity.DefaultIdFormat = ActivityIdFormat.W3C; |
|
Activity.ForceDefaultIdFormat = true; |
|
} |
|
else |
|
{ |
|
Activity.DefaultIdFormat = ActivityIdFormat.Hierarchical; |
|
Activity.ForceDefaultIdFormat = true; |
|
} |
|
}); |
|
} |
The setter deals with static properties on Activity and having two different instances of configuration with different settings is not possible.
So logically it should be static.
ApplicationInsights-dotnet/src/Microsoft.ApplicationInsights/Extensibility/TelemetryConfiguration.cs
Lines 185 to 201 in 521a84d
The setter deals with static properties on Activity and having two different instances of configuration with different settings is not possible.
So logically it should be static.