Hi!

We are using different appenders with a pattern layout that both read
values from ThreadContext using %X and through a custom lookup that
internally access the ThreadContext

If we use a pattern such as "%X{testkey} $${m:testkey} %m" (the lookup
assigned to prefix m access the same key from the ThreadContext) and then
use our appender in an AsyncLogger then we get the correct value for the
%X{testkey} but not for $${m:testkey}.

I assume the message is formatted on the caller thread but that the lookup
part of the pattern is resolved on the async thread since it does not seem
to find the key in the ThreadContext inside our lookup class?

Is the above the root cause to our problem? Is there a way around this? We
really would like to use our custom lookup that use ThreadContext with
async loggers.

Any help would be greatly apreciated
Best regards
LF

-- 
Med vänlig hälsning / Best regards

Lars-Fredrik Smedberg

STATEMENT OF CONFIDENTIALITY:
The information contained in this electronic message and any
attachments to this message are intended for the exclusive use of the
address(es) and may contain confidential or privileged information. If
you are not the intended recipient, please notify Lars-Fredrik Smedberg
immediately at itsme...@gmail.com, and destroy all copies of this
message and any attachments.

Reply via email to