3 messages in org.apache.logging.log4j-userDifferent logging levels for each lib...
FromSent OnAttachments
JordiJun 7, 2004 8:37 am 
Ceki GülcüJun 7, 2004 9:16 am 
Larry YoungJun 7, 2004 1:50 pm 
Actions with this message:
Paste this link in email or IM:
Paste this link in email or IM:
Atom feed for this thread
Paste this URL into your reader:
Subject:Different logging levels for each library client applicationActions...
From:Jordi (jba@hotmail.com)
Date:Jun 7, 2004 8:37:45 am
List:org.apache.logging.log4j-user

Hi,

I have a library with a small number of public methods, every method carrying a
"client application id" parameter.

The number of different client ids can be between 3 and 10, no more.

I'd like to be able to set different logging levels for each client id.

My first guess was to set up parallel hierarchies like

- client1.com.wombat.clazz

- client2.com.wombat.clazz

so that I can set log4j.logger.client1=DEBUG and log4j.logger.client2=INFO

but I'm afraid that would impact performance negatively as I would have to call
getLogger in each method call to retrieve the right logger for the request's
client id.

Has anyone faced this problem before and found a better approach?