Closed stevejgordon closed 6 years ago
I accomplished essentially the same thing by passing in a simple Func
@stevejgordon Do you have any time to implement this at some point soon?
@Franklin89 Still thinking about it, just haven't had the time as yet.
This work is completed and available since v2.0.0 https://github.com/stevejgordon/CorrelationId/releases/tag/rel%2F2.0.0
Currently the correlation ID is only exposed via the existing HttpContext.TraceIdentifier. This requires either access to the HttpContext or an IHttpContextAccessor to be able to get to the correlation ID.
I'm considering creating a custom "CorrelationContext" which will be available through DI so that the correlation ID can be more easily exposed in classes that don't already have easy access to HttpContext.