Closed EricDahlvang closed 1 year ago
@EricDahlvang, TRACE
events seem to correspond to individual lines of stderr
, i.e. there will be entries for each line of a stack trace. Even a regular console.error(new Error("stderr"))
yields the following in the transaction search log:
That said, using trackException
produces a more useful entry:
This expands to:
I don't think there's anything useful we can do here aside from possibly using the telemetry client to call trackException
in the Bot Adapter onTurnError
handler. What do you think?
That's odd. This would at lest produce a single line in the log: console.log(JSON.stringify(new Error("stderr")))
trackException
looks best though!
It looks like Application Insights is switching to #azure/log soon: https://github.com/microsoft/ApplicationInsights-node.js/pull/733 maybe this will help?
Hi @EricDahlvang and @joshgummersall We tried to reproduce the issue without success, using both a Composer bot and a bot sample.
console.error(new Error("stderr"))
, thrown when the beginDialog
is executed and then captured by the onTurnError
handler, the Application Insights showed a singular trace instead of multiple.
Regarding Composer, is there any telemetry configuration we are missing?, causing the traces to not be properly shown in Application Insights? Here is the configuration we used to connect to the Application Insights.
"telemetry": {
"logActivities": true,
"logPersonalInformation": true,
"options": {
"connectionString": "InstrumentationKey=<INSTRUMENTATION_KEY>;IngestionEndpoint=https://westus-0.in.applicationinsights.azure.com/"
}
}
Versions
4.13.1 Deployed Azure function bot from Composer
Describe the bug
DialogContextError are split in app insights telemetry logs into multiple entries (see image below)
To Reproduce
Steps to reproduce the behavior:
Screenshots