This will make it easy to remove any default telemetry modules.
The current way to remove a module is:
var performanceCounterService = services.FirstOrDefault(t => t.ImplementationType == typeof(PerformanceCollectorModule));
if (performanceCounterService != null)
{
services.Remove(performanceCounterService);
}
Proposed way to remove, for example, DependencyCollection would be:
var aiOptions = new ApplicationInsightsServiceOptions();
// Disables adaptive sampling.
aiOptions.EnableDependencyCollection = false;
services.AddApplicationInsightsTelemetry(aiOptions);
There are around 7 modules present by default, and hence there should be 7 new fields with all modules enabled by default.
This will make it easy to remove any default telemetry modules.
The current way to remove a module is: var performanceCounterService = services.FirstOrDefault(t => t.ImplementationType == typeof(PerformanceCollectorModule));
if (performanceCounterService != null)
{
services.Remove(performanceCounterService);
}
Proposed way to remove, for example, DependencyCollection would be:
There are around 7 modules present by default, and hence there should be 7 new fields with all modules enabled by default.