Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > Problems with org.apache.log4j.PatternLayout format specifiers?

Reply
Thread Tools

Problems with org.apache.log4j.PatternLayout format specifiers?

 
 
Pep
Guest
Posts: n/a
 
      10-11-2005
Or my understanding of the specifications?

I have this specification in my configuration file

log4j.appender.A1.layout.ConversionPattern=%d{dd MMM yyyy HH:mm:ss z}: %-5p
[%t] %8x - %m%n

But the messages in the log file do not contain the name of the tread as I
believe that %t is supposed to do. Instead they contain the name of the
class contained in the thread.

I have checked this by including the name of the thread, using getName(), in
the message and sure enough the %t formatter is only printing the name of
the class not the name of the thread

Is %t supposed to show the name of the class, in which case it is my
misunderstanding of the documentation or should it show the name of the
thread in which case there is a problem?

TIA,
Pep.

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Money Format + Decimal Place Format shannon Java 1 02-02-2006 03:47 PM
Money Format + Decimal Place Format shannon Java 0 02-01-2006 10:02 PM
need code to convert float format to internal java float format which is kept in 4 bytes integer Andy Java 7 05-10-2004 09:26 PM
NTFS quick format and normal format Guan Foo Wah MCSE 2 05-08-2004 11:35 PM
Date Format - best way of converting a string into a date format Brian Candy ASP .Net 2 02-18-2004 02:13 PM



Advertisments