Closed dglozano closed 3 years ago
I ran into the same issue the only difference is that I'm using this extension from a Generic Host, so the AddApplicationInsightsTelemetry
does not work in that scenario, you should use AddApplicationInsightsTelemetryWorkerService
from Microsoft.ApplicationInsights.WorkerService
. So would be nice to add it to the documentation too, I can do it if you want me to do so.
@vany0114 not sure if instructions to setup ApplicationInsights itself would belong in the Serilog's sink documentation, but I guess it doesn't hurt either 😄 Feel free to add it
@dglozano I think would be nice just to mention that if you're using a Generic Host you need to use AddApplicationInsightsTelemetryWorkerService
rather than AddApplicationInsightsTelemetry
(Asp.Net projects) otherwise it does not work, just for the benefit of everyone who runs into that issue (I spent a couple of hours on that)
@vany0114 sorry for the delay, it's merged now 😄
This information really need merging in
After going through the thread #121 in order to be able to configure the Sink properly, I thought it might be useful to update the README.md with the instructions on how to set the logger in .NET Core applications after
TelemetryConfiguration.Active
was deprecated 😄