© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
C#C
C#•2y ago•
4 replies
Esa

HttpContext and TraceIdentifier

Anybody familiar with how the TraceId of HttpContext works?
I am aware it represents a {TraceIdentifier}:{Span} format with the former being the overall identifier of an Activity and the latter being a specific sub-operation performed in the context of that activity. But I don't understand when one activity starts and another one stops.

I tried performing multiple repeat API requests through swagger, and they all got the same TraceIdentifier but incrementing Spans.

Can anyone clarify what is happening? I have a common .net 8.0 setup of program.cs for a WebAPI solution.
C# banner
C#Join
We are a programming server aimed at coders discussing everything related to C# (CSharp) and .NET.
61,871Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

❔ HttpContext reading Request and Response body
C#CC# / help
3y ago
✅ How to make httpcontext threadsafe?
C#CC# / help
11mo ago
HttpContext.Current doesn't exist
C#CC# / help
4y ago
Issue with httpContext and cascadingParamter in blazor web app
C#CC# / help
2y ago