RE: Problem configuring log4j with common classes

2003-06-19 Thread Shapira, Yoav
mailto:[EMAIL PROTECTED] >Sent: Thursday, June 19, 2003 1:53 PM >To: [EMAIL PROTECTED] >Subject: RE: Problem configuring log4j with common classes > >im trying to get configure code that works in dual-use components ( java >app. or WebApp ). > >My question is at bottom of post

RE: Problem configuring log4j with common classes

2003-06-19 Thread robert rowntree
im trying to get configure code that works in dual-use components ( java app. or WebApp ). My question is at bottom of post... The following configure code works fine in a WebApp on TomCat * * * * * * * java code causing the exception : PropertyConfigurator * * * * * * * static {

RE: Problem configuring log4j with common classes

2003-06-12 Thread Carlos Roberto Yaconi Hitschfeld
Finally it worked!!! Thank you very much for your help. Best Regards! Carlos Yaconi Hitschfeld -Mensaje original- De: Jacob Kjome [mailto:[EMAIL PROTECTED] Enviado el: Jueves, 12 de Junio de 2003 13:51 Para: Log4J Users List Asunto: RE: Problem configuring log4j with common classes

RE: Problem configuring log4j with common classes

2003-06-12 Thread Jacob Kjome
ilto:[EMAIL PROTECTED] Enviado el: Jueves, 12 de Junio de 2003 12:45 Para: Log4J Users List Asunto: RE: Problem configuring log4j with common classes If you load the properties file with a file name, it will look for the file in the location where the java process was started unless you provide an abso

Re: Problem configuring log4j with common classes

2003-06-12 Thread Erik Price
Carlos Roberto Yaconi Hitschfeld wrote: Thanks... But, can you give some example please?? I'm newbie with log4j and I don't know how to do it. Erik

RE: Problem configuring log4j with common classes

2003-06-12 Thread Carlos Roberto Yaconi Hitschfeld
2003 12:45 Para: Log4J Users List Asunto: RE: Problem configuring log4j with common classes If you load the properties file with a file name, it will look for the file in the location where the java process was started unless you provide an absolute path to the file. The better way to do this

RE: Problem configuring log4j with common classes

2003-06-12 Thread Jacob Kjome
Atte, Carlos Yaconi Hitschfeld Anexo: 8-4619 Teléfono: 388-4619 -Mensaje original- De: Alison Ortega [mailto:[EMAIL PROTECTED] Enviado el: Miércoles, 11 de Junio de 2003 14:24 Para: [EMAIL PROTECTED] Asunto: RE: Problem configuring log4j with common classes What you have looks right, just do a stat

RE: Problem configuring log4j with common classes

2003-06-12 Thread Carlos Roberto Yaconi Hitschfeld
-4619 -Mensaje original- De: Alison Ortega [mailto:[EMAIL PROTECTED] Enviado el: Miércoles, 11 de Junio de 2003 14:24 Para: [EMAIL PROTECTED] Asunto: RE: Problem configuring log4j with common classes What you have looks right, just do a static initializer block in your common classes li

RE: Problem configuring log4j with common classes

2003-06-11 Thread Alison Ortega
What you have looks right, just do a static initializer block in your common classes like this: ... code to get the init file name and prefix ... static { PropertyConfigurator.configure(prefix+file); } It goes in the class/instance data declarations section of your common class. I suppose you cou

RE: Problem configuring log4j with common classes

2003-06-11 Thread Carlos Roberto Yaconi Hitschfeld
isunderstanding, but I can't solve this puzzle! Again, THANK YOU SO MUCH!!! Best Regards! Carlos Yaconi Hitschfeld -Mensaje original- De: Alison Ortega [mailto:[EMAIL PROTECTED] Enviado el: Miércoles, 11 de Junio de 2003 12:47 Para: [EMAIL PROTECTED] Asunto: RE: Problem configuring

RE: Problem configuring log4j with common classes

2003-06-11 Thread Alison Ortega
Sure. Here's the basic structure imports... public class CommonClass { class/instance data declarations... static { DOMConfigurator.configureAndWatch(logInitFile); } methods... } where logInitFile is an xml file that only declares the root category and appenders. http://jakarta.apache.org/log

RE: Problem configuring log4j with common classes

2003-06-11 Thread Carlos Roberto Yaconi Hitschfeld
-- De: Alison Ortega [mailto:[EMAIL PROTECTED] Enviado el: Miércoles, 11 de Junio de 2003 12:02 Para: [EMAIL PROTECTED] Asunto: Re: Problem configuring log4j with common classes I have a similar scenario - what I ended up doing is running an init (configure method) in an init servlet for

Re: Problem configuring log4j with common classes

2003-06-11 Thread Alison Ortega
I have a similar scenario - what I ended up doing is running an init (configure method) in an init servlet for each application and a static init in my common classes. The root appender is configured in my common classes, and each app has it's own category(ies)/appenders. Since each time you run

Problem configuring log4j with common classes

2003-06-11 Thread Carlos Roberto Yaconi Hitschfeld
Hi! I'm currently developing applications for a big enterprise, which consist on common classes that has our own connection framework (middleware), to a proprietary back-end system, and a lot of different web applications that has is own logic, and uses this common connector. My trouble is when