Looking for Resources to Master Azure Application Insights with .NET Logging

0
20
Asked By CuriousCoder99 On

Hey everyone! I'm currently using Azure Application Insights with ILogger in my .NET projects, but I really want to refine my skills and learn best practices for logging with Application Insights. If you've got any tutorials, guides, or just some personal insights on how to set up effective logging and telemetry, I'd love to hear your recommendations! Thanks a lot!

4 Answers

Answered By SmartLogger11 On

When logging, focus on custom information that is likely to be useful for troubleshooting. Choose a sampling rate that fits your needs; you don’t need to log everything. Averages generally suffice for telemetry, and remember, storing data for longer periods doesn't cost significantly more. Custom metrics can really help you understand application workflows better. Just be cautious with App Insights, as it can get expensive compared to alternatives like DataDog; use it wisely!

CuriousCoder99 -

Thanks for the insights!

Answered By TechieTraveler7 On

OpenTelemetry is becoming the go-to standard for logs, metrics, and traces in the industry. The Azure Monitor SDK is built on top of this, making it easier to integrate with Application Insights. Check out the official docs for help with getting started:
- [OpenTelemetry in Azure](https://learn.microsoft.com/en-us/azure/azure-monitor/app/opentelemetry-enable?tabs=aspnetcore)
- [OpenTelemetry .NET Docs](https://opentelemetry.io/docs/languages/dotnet/).
If you're working with distributed applications, Aspire has great support for OpenTelemetry and even more features. They’ve got a nifty dashboard that became so popular, Microsoft made a container image for it!
- [Aspire Dashboard Overview](https://learn.microsoft.com/en-us/dotnet/aspire/fundamentals/dashboard/overview?tabs=bash)
Both SDKs come with solid auto instrumentation too – definitely check the default logs and modify as needed. And don’t miss the .NET YouTube channel’s new series about adding custom metrics, logs, and traces!

HelpfulHacker5 -

Thank you for the resources!

Answered By DataDude88 On

Sampling is key! If you want your logging to be effective at scale, configuring your sampling rate is vital. You need to distinguish between useful info and data that clutters your insights. Get that right, and it can make all the difference in troubleshooting issues down the line.

CuriousCoder99 -

Great point, I’ll definitely keep that in mind.

Answered By DevGuru23 On

Make sure to set daily ingestion limits to manage your data effectively. While it might seem trivial, doing this is crucial and helps avoid unnecessary costs in the long run. After that, the specifics don’t matter as much, but Step 1 is a must!

CuriousCoder99 -

Thanks for the tip!

Related Questions

LEAVE A REPLY

Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.