Re: separate log files

2007-01-16 Thread Yonik Seeley

I wonder of jetty or tomcat can be configured to put logging output
for different webapps in different log files...

-Yonik

On 1/15/07, Ben Incani [EMAIL PROTECTED] wrote:

Hi Solr users,

I'm running multiple instances of Solr, which all using the same war
file to load from.

Below is an example of the servlet context file used for each
application.

Context path=/app1-solr docBase=/var/usr/solr/solr-1.0.war
debug=0 crossContext=true 
Environment name=solr/home type=java.lang.String
value=/var/local/app1 override=true /
/Context

Hence each application is using the same
WEB-INF/classes/logging.properties file to configure logging.

I would like to each instance to log to separate log files such as;
app1-solr.-mm-dd.log
app2-solr.-mm-dd.log
...

Is there an easy way to append the context path to
org.apache.juli.FileHandler.prefix
E.g.
org.apache.juli.FileHandler.prefix = ${catalina.context}-solr.

Or would this require a code change?

Regards

-Ben


Re: separate log files

2007-01-16 Thread Chris Hostetter

: I wonder of jetty or tomcat can be configured to put logging output
: for different webapps in different log files...

i've never tried it, but the tomcat docs do talk about
tomcat providing a custom implimentation of java.util.logging specificly
for this purpose.

Ben: please take a look at this doc...

http://tomcat.apache.org/tomcat-5.5-doc/logging.html

..specifically the section on java.util.logging (since that's what Solr
uses) ... I believe you'll want something like the Example
logging.properties file to be placed in common/classes so that you can
control the logging.

Please let us all know if this works for you ... it would make a great
addition to the SolrTomcat wiki page.


: On 1/15/07, Ben Incani [EMAIL PROTECTED] wrote:
:  Hi Solr users,
: 
:  I'm running multiple instances of Solr, which all using the same war
:  file to load from.
: 
:  Below is an example of the servlet context file used for each
:  application.
: 
:  Context path=/app1-solr docBase=/var/usr/solr/solr-1.0.war
:  debug=0 crossContext=true 
:  Environment name=solr/home type=java.lang.String
:  value=/var/local/app1 override=true /
:  /Context
: 
:  Hence each application is using the same
:  WEB-INF/classes/logging.properties file to configure logging.
: 
:  I would like to each instance to log to separate log files such as;
:  app1-solr.-mm-dd.log
:  app2-solr.-mm-dd.log
:  ...
: 
:  Is there an easy way to append the context path to
:  org.apache.juli.FileHandler.prefix
:  E.g.
:  org.apache.juli.FileHandler.prefix = ${catalina.context}-solr.
: 
:  Or would this require a code change?
: 
:  Regards
: 
:  -Ben
:



-Hoss



separate log files

2007-01-15 Thread Ben Incani
Hi Solr users,

I'm running multiple instances of Solr, which all using the same war
file to load from.

Below is an example of the servlet context file used for each
application.

Context path=/app1-solr docBase=/var/usr/solr/solr-1.0.war
debug=0 crossContext=true 
Environment name=solr/home type=java.lang.String
value=/var/local/app1 override=true /
/Context

Hence each application is using the same
WEB-INF/classes/logging.properties file to configure logging.

I would like to each instance to log to separate log files such as;
app1-solr.-mm-dd.log
app2-solr.-mm-dd.log
...

Is there an easy way to append the context path to
org.apache.juli.FileHandler.prefix
E.g. 
org.apache.juli.FileHandler.prefix = ${catalina.context}-solr.
 
Or would this require a code change?

Regards

-Ben