You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jun 10, 2020. It is now read-only.
Provide an ability to configure any TelemetryModule in an easy way as opposed to the following documented way.
Configuring Telemetry Module Services
Inorder to configure any properties of TelemetyModules, obtain the module from DI Container first. Then modify the required properties, and re-initialize the module with currently active Telemetry Configuration.
For eg:, to modify DependencyTrackingTelemetryModule to disable setting Correlationheaders, the following code is required in the Configure method of you Startup class.
DependencyTrackingTelemetryModule dep;
var modules = app.ApplicationServices.GetServices();
foreach(var module in modules)
{
if (module is DependencyTrackingTelemetryModule)
{
dep = module as DependencyTrackingTelemetryModule;
dep.SetComponentCorrelationHttpHeaders = false;
dep.Initialize(TelemetryConfiguration.Active);
}
}
Provide an ability to configure any TelemetryModule in an easy way as opposed to the following documented way.
Configuring Telemetry Module Services
Inorder to configure any properties of TelemetyModules, obtain the module from DI Container first. Then modify the required properties, and re-initialize the module with currently active Telemetry Configuration.
For eg:, to modify DependencyTrackingTelemetryModule to disable setting Correlationheaders, the following code is required in the Configure method of you Startup class.
DependencyTrackingTelemetryModule dep;
var modules = app.ApplicationServices.GetServices();
foreach(var module in modules)
{
if (module is DependencyTrackingTelemetryModule)
{
dep = module as DependencyTrackingTelemetryModule;
dep.SetComponentCorrelationHttpHeaders = false;
dep.Initialize(TelemetryConfiguration.Active);
}
}