tomcat-taglibs-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mark R. Diggory" <mdigg...@latte.harvard.edu>
Subject Re: Taglibs and Commons Logging
Date Tue, 17 Dec 2002 20:35:01 GMT
I've been attempting this strategy, but it seems that in the web 
application, somehow the properties files in the classes directory don't 
seem to get recognized by commons logging and used. When I compile my 
tags, they get deployed into jars in the WEB-INF /lib directory. I'm 
concerned that the libs endup on the classpath before the properties 
files, I'm wondering if theres a chance that its not searching the whole 
classpath when seaching for the properties files. Am I missing something?

Here's my layout:

/WEB-INF/classes/commons-logging.properties

    org.apache.commons.logging.Log=org.apache.commons.logging.impl.SimpleLog

/WEB-INF/classes/simplelog.properties

    org.apache.commons.logging.simplelog.defaultlog=trace
    org.apache.commons.logging.simplelog.showdatetime=true

/WEB-INF/lib/commons-logging.jar
/WEB-INF/lib/commons-logging-api.jar
/WEB-INF/lib/mytags.jar

And I don't see any log events in catalina.out for the log.debug(...) 
calls I'm making in my classes.

-Mark

Karr, David wrote:

>Struts uses commons-logging.  If you put a "commons-logging.properties"
>file in your WEB-INF/classes directory, with the following contents:
>
>org.apache.commons.logging.Log	=
>org.apache.commons.logging.impl.SimpleLog
>
>Then, you can have a file named "simplelog.properties" in the same
>place, with contents like:
>
>org.apache.commons.logging.simplelog.defaultlog	= warn
>
>Other systems using commons-logging will probably work the same way.
>
>  
>
>>-----Original Message-----
>>From: Mark R. Diggory [mailto:mdiggory@latte.harvard.edu]
>>
>>I'm trying to find the best way to integrate commons-logging into my 
>>taglibs. Do any of the jakarta taglibraries use the Commons API for 
>>logging? If so, how do you configure the environment so that the 
>>appropriate logging facility is picked up and used? I'm struggling to 
>>get the default be the Simple logger, then other Logging 
>>implementations 
>>be used if availble. But I can't see how to do it simply within the 
>>taglibary/Jatr for my project.
>>
>>Any tips would be helpfull,
>>-Mark
>>
>>
>>--
>>To unsubscribe, e-mail:   
>><mailto:taglibs-user-unsubscribe@jakarta.apache.org>
>>For additional commands, e-mail: 
>><mailto:taglibs-user-help@jakarta.apache.org>
>>
>>    
>>
>
>--
>To unsubscribe, e-mail:   <mailto:taglibs-user-unsubscribe@jakarta.apache.org>
>For additional commands, e-mail: <mailto:taglibs-user-help@jakarta.apache.org>
>
>  
>




--
To unsubscribe, e-mail:   <mailto:taglibs-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:taglibs-user-help@jakarta.apache.org>


Mime
View raw message