windows-identity and multi-threaded apps...

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

windows-identity and multi-threaded apps...

mrochotte
Hi all.

I have a question about the value for ${windows-identity} in multi-threaded apps.

Is the value retrieved at the time the message is sent to the logger, or is it retrieved when the message is rendered for the layout?

thanks,

mark
Reply | Threaded
Open this post in threaded view
|

Re: windows-identity and multi-threaded apps...

Jarek Kowalski
Administrator
That depends - if you're using non-asynchronous logging, it's
retrieved when rendering, for asynchronous/buffered logging it's
computed before the log event is added to the buffer.

In any case - the value rendered should always be correct. Are you
seeing something else?

Jarek
NLog Blog