开发者

Problem configuring application specific loggin glassfish v3

开发者 https://www.devze.com 2022-12-23 04:39 出处:网络
I am using java.util.logging in开发者_如何学Python an EJB application running on glassfish v3. I can see the log messages in server.log but i don\'t seem to be able to configure the logging level in g

I am using java.util.logging in开发者_如何学Python an EJB application running on glassfish v3. I can see the log messages in server.log but i don't seem to be able to configure the logging level in glassfish\domains\domain1\config\logging.properties. If I use:

Logger logger = Logger.getLogger("com.foo");

To obtain the logger and log with:

logger.info("message");

then I expect that if I set

com.foo.level=WARNING 

in logging.properties then the message should not logged. Am I doing something wrong here?


If you use .level=WARNING, only WARNING and above severities will be logged. You will have to set it to FINEST, FINER, FINE, CONFIG or INFO to have logger.info(anything) actually do something.

0

精彩评论

暂无评论...
验证码 换一张
取 消