Logsedit

Elastic .NET Agent provides Log correlation. The agent will automaticaly inject correlation IDs that allow navigation between logs, traces and services.

This features is part of Application log ingestion strategies.

The ecs-logging-dotnet library can also be used to use the ECS logging format without an APM agent. ECS .NET logging will always provide log correlation IDs through System.Diagnostics.Activity. When paired with the APM Agent it will pick up the appropriate service correlation features too.

Log correlationedit

The Elastic APM .NET agent provides integrations for popular logging frameworks, which take care of injecting trace ID fields into your application’s log records. Currently supported logging frameworks are:

If your favorite logging framework is not already supported, there are two other options:

  • Open a feature request, or contribute code, for additional support, as described in CONTRIBUTING.md.
  • Manually inject trace IDs into log records, as described in Manual log correlation.

Regardless of how you integrate APM with logging, you can use Filebeat to send your logs to Elasticsearch, in order to correlate your traces and logs and link from APM to the Logs app.