struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Adam Hardy <ahardy.str...@cyberspaceroad.com>
Subject Re: log 4 j error in struts 1.2.8
Date Wed, 19 Apr 2006 10:00:20 GMT
Hi Raghuveer,

this means that you have either not configured a logger in 
log4j.properties / log4j.xml, or that java is not finding the file.

Your logger name which you are getting with getLogger(cal.getTime) is 
highly unusual! Such an approach would be virtually impossible to 
configure properly in the config files, since you have to name the 
loggers explicitly.

Try running through the short documentation at Jakarta. It's good.


Adam



Raghuveer on 19/04/06 08:43, wrote:
> I am using struts1.2.8 with hibernate 3.
> 
> I am getting below error.
> Is there any solution for this problem ?
> ----------------------------------------------------
> private DailyRollingFileAppender cAeroAppender;
> 	java.util.Calendar cal=java.util.Calendar.getInstance(); // getting
> calendar instance
> 				logger = Logger.getLogger(cal.getTime()+"");
> 
> 
> strLogLevel=CAeroConstants.getProperty(CAeroConstants.PROPTYPE_CONFIG,CAeroC
> onstants.CONFIGPROP_LOG_LEVEL);
> 					logger.setLevel(Level.DEBUG);
> 				}
> 				else if ( strLogLevel.equalsIgnoreCase("DEBUG") ) {
> 					logger.setLevel(Level.DEBUG);
> 				}
> 				else if ( strLogLevel.equalsIgnoreCase("ERROR") ) {
> 					logger.setLevel(Level.ERROR);
> 				}
> 
> 
> 				cAeroAppender = new DailyRollingFileAppender(new
> SimpleLayout(),strLogPath+".log","'_'MM-dd-yyyy");
> 				logger.addAppender(cAeroAppender);
> 
> -----------------------------
> 
> 
> 06/04/18 20:50:01 log4j:WARN No appenders could be found for logger
> (org.apache.struts.util.PropertyMessageResource
> s).
> 06/04/18 20:50:01 log4j:WARN Please initialize the log4j system properly.
> ---------------------------------
> Raghu
> 
> 
> 
> 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message