accessing xml properties in war file

2003-01-14 Thread Carey Boldenow
Hi, I am attempting to deploy a web application in WebLogic via a war file. Since I have no way of determing the actual path that Weblogic will use for deploying my war file, I need a way to access my xml file that holds my log4j properties. I can use servletContext.getResourceAsStream() to g

Re: accessing xml properties in war file

2003-01-14 Thread Jacob Kjome
Hello Carey, See the Log4jInit servlet and Log4jApplicationWatch servlet context listener in Barracuda. These provide exactly what you need. http://barracuda.enhydra.org/software/cvs/cvsweb.cgi/Projects/EnhydraOrg/toolsTech/Barracuda/src/org/enhydra/barracuda/webapp/log4j/ http://barracuda.enhyd

Re: accessing xml properties in war file

2003-01-14 Thread Jacob Kjome
Hello Carey, Note that the stuff about Barracuda in my previous message will be moving to Log4j-1.3. Some have already moved (ContextClassLoaderSelector). However, for the time being, things will exist in both places until Log4j-1.3 is released. Just wanted to point that out. Jake Tuesday, Ja

RE: accessing xml properties in war file

2003-01-14 Thread Mark Womack
Hey Jacob, Did you submit a version of the init servlet with the apache headers, etc? I can check it into cvs if you have. Maybe I missed it. -Mark > -Original Message- > From: Jacob Kjome [mailto:[EMAIL PROTECTED]] > Sent: Tuesday, January 14, 2003 11:04 AM > To: Log4J Developers List

Re: accessing xml properties in war file

2003-01-14 Thread Carey Boldenow
Thanks Jacob, If you could pass on your updated code when you have time, I would greatly appreciate that. Regards, Carey On Tue, 14 Jan 2003 13:03:56 -0600 Jacob Kjome <[EMAIL PROTECTED]> wrote: Hello Carey, Note that the stuff about Barracuda in my previous message will be moving to Log4j-1

Re: accessing xml properties in war file

2003-01-14 Thread Jacob Kjome
Here is the promised initialization setup. Read "Usage.txt" in the attached zip file.  I included both source and pre-built jars.  I also included a sample logj4.xml file.  See Usage.txt for specifics on what is unique about this log4j.xml file and for other info like web.xml config. Oh, and Mar

Re: accessing xml properties in war file

2003-01-14 Thread Carey Boldenow
Hello Jacob, Thanks for the code and examples, looks to be exactly what I need. My only question is, and using your examples as reference, if I am deploying my web app via a .war file, and I want to create a FileAppender, do I have to hard code the physical path for the file in my log4j.xml. I

Re: accessing xml properties in war file

2003-01-14 Thread Jacob Kjome
Hi Carey, Ah, you bring up a good point. One should be able to set a directory outside the .war file by setting the config in the web.xml and the system property should be able to be set to that. That was an oversight which happened, probably, because I never run the context directly from a

Re: accessing xml properties in war file

2003-01-14 Thread Jacob Kjome
Ug, Upon further examination of my code, it turns out I knew what I was doing after all. If you set the "log4j-log-home" context parameter in web.xml (currently commented out because it is an optional parameter which will always be system specific if supplied), then you *can* set the system