Re: Filters

2006-11-09 Thread James Stauffer
Then I would suggest looking toto modifying the LoggingEvent message. On 11/9/06, vincentw <[EMAIL PROTECTED]> wrote: darn...I believe we are using 1.29 Jacob Kjome wrote: > > Quoting James Stauffer <[EMAIL PROTECTED]>: > >> Code in log4j should only use LogLog for logging > > Note that this

Re: Filters

2006-11-09 Thread vincentw
darn...I believe we are using 1.29 Jacob Kjome wrote: > > Quoting James Stauffer <[EMAIL PROTECTED]>: > >> Code in log4j should only use LogLog for logging > > Note that this is true for Log4j versions previous to 1.3alpha, but as of > 1.3alpha, Log4j uses itself for logging (except for the s

Re: Syslog logging configuration

2006-11-09 Thread Ceki Gülcü
At 10:12 PM 11/9/2006, you wrote: I vaguely remember that we had security issues when we started using the SyslogAppender. Make sure you have the privileges to connect to it via a socket. Most C/C++ apps use the syslog system call, but I believe log4j uses a TCP socket to talk to the syslog daem

Re: Syslog logging configuration

2006-11-09 Thread Maarten Bosteels
I vaguely remember that we had security issues when we started using the SyslogAppender. Make sure you have the privileges to connect to it via a socket. Most C/C++ apps use the syslog system call, but I believe log4j uses a TCP socket to talk to the syslog daemon. Maarten On 11/9/06, Joni Hahk

Re: Log4j 1.2.9, 64-bit, Websphere Performance Problems

2006-11-09 Thread matt.accola
It turned out to be the use of %C %l in PatternLayout. Removing that took the per log timings back down to sub-millisecond level. Crazy! I guess I should have heeded the warnings in the JavaDocs. -- View this message in context: http://www.nabble.com/Log4j-1.2.9%2C-64-bit%2C-Websphere-Perform

Re: dynamically adding to a log file name?

2006-11-09 Thread Chris Cheshire
DohI got this solved, I used < > entities in the layout specification and it worked. Thanks for the help James, the MDC helps with the logging of a comment at the end of the file, and that combined with your DateFormatFileAppender is good enough for what I need. Cheers Chris On 11/9/06, Ch

Re: dynamically adding to a log file name?

2006-11-09 Thread Chris Cheshire
On 11/9/06, James Stauffer <[EMAIL PROTECTED]> wrote: Search the archives for people who wanted a separate log per MDC value (usually login name). OK I found the MDC section in the manual and it looks to be what I need *except* I cannot create XML style comments in the log file to contain the

Syslog logging configuration

2006-11-09 Thread Joni Hahkala
Hi, I'm trying to log to syslog, but I can't get it to work. Bought the manual, but it doesn't say anything, and googling for it I only found one example in the manual review. So, I'm trying with configuration: log4j.logger.org.glite.security=DEBUG, syslog log4j.appender.syslog=org.apache.l

Re: dynamically adding to a log file name?

2006-11-09 Thread James Stauffer
Search the archives for people who wanted a separate log per MDC value (usually login name). On 11/9/06, Chris Cheshire <[EMAIL PROTECTED]> wrote: Thanks James, I'll look into this. I think I can guarantee a unique id as the requests are unique and the logging for the request and response are do

Re: dynamically adding to a log file name?

2006-11-09 Thread Chris Cheshire
Thanks James, I'll look into this. I think I can guarantee a unique id as the requests are unique and the logging for the request and response are done in the same method. On 11/9/06, James Stauffer <[EMAIL PROTECTED]> wrote: You could look into including some MDC value in the filename (assuming

Re: dynamically adding to a log file name?

2006-11-09 Thread Chris Cheshire
Because the request is generated in a library not an application. The library has no concept of what container it is running in or where it should save files. I felt log4j was the best solution for this as it allows me to turn this on and off at will and goes with the trace info I have in there al

Re: Filters

2006-11-09 Thread Jacob Kjome
Quoting James Stauffer <[EMAIL PROTECTED]>: > Code in log4j should only use LogLog for logging Note that this is true for Log4j versions previous to 1.3alpha, but as of 1.3alpha, Log4j uses itself for logging (except for the short time prior to bootstrapping itself). Jake >, which is only sent

Re: dynamically adding to a log file name?

2006-11-09 Thread James Stauffer
You could look into including some MDC value in the filename (assuming you can assign a unique id to each request/response pair). On 11/8/06, Chris Cheshire <[EMAIL PROTECTED]> wrote: Hi, I have a process that sends an xml request to an external server and receives an xml response back. For pur

Re: Filters

2006-11-09 Thread James Stauffer
Code in log4j should only use LogLog for logging, which is only sent to standard out. I don't have any good ideas unless you change the message of the LogEvent that gets through. On 11/8/06, vincentw <[EMAIL PROTECTED]> wrote: Hi, I'm trying to filter the log message and I can do it. But I w

Re: dynamically adding to a log file name?

2006-11-09 Thread Maarten Bosteels
Why don't you just save the request and the response to a file ? You do not need log4j for that, right ? DateFormat df = new SimpleDateFormat("MMdd-HHmmss-S"); String filename = "/tmp/" + df.format(new Date()) + "-request.xml"; FileWriter writer = new FileWriter(filename);