we are using Nodejs - AZURE Functions
Application Insight Sdk and instrumentation to track end to end logs.
The logs are started appearing twice and hence making lot of chaos in analyzing.
// host.json config
{
"aggregator": {
"batchSize": 1000,
"flushTimeout": "00:00:30"
},
"logging": {
"console": {
"isEnabled": "false"
},
"fileLoggingMode": "always",
"logLevel": {
"default": "Information",
"Host.Results": "Information",
"Function": "Information",
"Host.Aggregator": "Information"
},
"applicationInsights": {
"samplingSettings": {
"isEnabled": false,
"maxTelemetryItemsPerSecond": 20,
"initialSamplingPercentage": 100.0,
"excludedTypes": "Dependency;Event;Request;Exception"
},
"enableLiveMetrics": false,
"enableDependencyTracking": false,
"enablePerformanceCountersCollection": false,
"httpAutoCollectionOptions": {
"enableHttpTriggerExtendedInfoCollection": true,
"enableW3CDistributedTracing": true,
"enableResponseHeaderInjection": true
}
}
}
}
//appInsight sdk config
appInsights
.setup(true)
.setAutoDependencyCorrelation(true)
.setAutoCollectRequests(true)
.setAutoCollectPerformance(true,true)
.setAutoCollectExceptions(true)
.setAutoCollectDependencies(true)
.setAutoCollectConsole(true)
.setUseDiskRetryCaching(true)
.setSendLiveMetrics(true)
.setDistributedTracingMode(appInsights.DistributedTracingModes.AI_AND_W3C)
.start();
Any fix for this issue?
Thanks in advance.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…