microsoft / ApplicationInsights-dotnet-server

Microsoft Application Insights for .NET Web Applications
https://azure.microsoft.com/services/application-insights/
133 stars 67 forks source link

When Activity has root id compatible with W3C Id, use it as trace id #1107

Closed lmolkova closed 5 years ago

lmolkova commented 5 years ago

The transition to W3C standard in customer distributed system starts with frontend service. The first service should generate W3C compatible operation id that could be used downstream on all services whether they support W3C or not.

This change checks

THEN is uses root id as traceid.

As a result when customer updates frontend to AppInsights 2.7+ and when it calls downstream service, it emits Request-Id = |traceId.1. and traceparent = 00-trace-id-spanId-00

This guarantees common operation id on all downstream services.

lmolkova commented 5 years ago

@MS-TimothyMothra please review