Think I figured this out; it appears to be related to the order things
happen.

I originally had my logging initialization as the first line in my
Application init() method.

Unfortunately this occurs after some of the class Loggers get initialized
statically and consequently our initialization occurs too late.

If I place my initialization as the first line of the constructor class or
as a static initialization everything appears to work properly.

This could also solve the problem of some people who have mentioned issues
with their formatters.

HTH

MZ


Martin Zardecki wrote:
> 
> Hi list, I'm using Java Utils Logging along with Wicket and I have a
> log.properties which I read in the WicketApplication init method as
> follows:
> 
> java.util.logging.LogManager.getLogManager().readConfiguration(input);
> 
> I confirm that my log.properties is read in correctly using a debugger.
> 
> ---
> My log.properties file is as follows:
> 
> # Specify the handlers to create in the root logger
> # (all loggers are children of the root logger)
> # The following creates two handlers
> handlers = java.util.logging.ConsoleHandler, java.util.logging.FileHandler
> 
> # Set the default logging level for the root logger
> .level = WARNING
> 
> # Set the default logging level for new ConsoleHandler instances
> java.util.logging.ConsoleHandler.level = ALL
> java.util.logging.ConsoleHandler.formatter =
> java.util.logging.SimpleFormatter
> 
> # Set the default logging level for new FileHandler instances
> java.util.logging.FileHandler.level = ALL
> java.util.logging.FileHandler.pattern = %h/stagetwo.log
> java.util.logging.FileHandler.limit = 50000
> java.util.logging.FileHandler.count = 1
> java.util.logging.FileHandler.formatter =
> java.util.logging.SimpleFormatter
> 
> # Set the default logging level for the logger named com.truecool
> com.truecool.stagetwo.level = WARNING
> 
> org.apache.wicket.level = WARNING
> org.apache.wicket.markup.resolver.WicketMessageResolver.level = SEVERE
> 
> # Hibernate Logging options
> #logger.org.hibernate=info
> org.hibernate.level = WARNING
> ---
> 
> For whatever reason I'm still getting all the WicketMessageResolver
> warnings in my logs.
> 
> Any suggestions on how to get rid of the WicketMessageResolver warnings?
> 
> Thanks,
> 
> Martin Zardecki
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
> 
> 
> 

-- 
View this message in context: 
http://old.nabble.com/Logging-configuration-trouble-tp26867097p26961354.html
Sent from the Wicket - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to