ahh, I missed this when I was looking at your config. Your
definition of the layout is not using nested <param..> to set the
configuration. Only the 'class' attribute in the <layout..> section
is used, all the others need to be nested <param..>s.
Try this layout configuration snippet instead (this is just one
copied from what I use)
...
<layout class="org.apache.log4j.PatternLayout">
<param name="ConversionPattern"
value="[%d{ISO8601} %-5p][%20.20c][%t] %m%n" />
</layout>
...
Paul
On 21/06/2007, at 8:15 AM, akshay kumar wrote:
HI ,
Thanks for help!
However %d{ISO8601} didnt work.
below are the few logs that I am getting in the log file, which
include just a message part nothing else.
Starting internal logs on console.
About to instantiate plugin of type
[org.apache.log4j.net.SocketReceiver]
plugin named as [SocketReceiver]
Pushing plugin on to the object stack.
In ParamAction setting parameter [Port] to value [4445].
Popping plugin named [SocketReceiver] from the object stack
no applicable action for <Param>, current pattern is [/
configuration/Param]
About to instantiate appender of type
[org.apache.log4j.RollingFileAppender]
Appender named as [RollingFile]
Pushing appender on to the object stack.
In ParamAction setting parameter [File] to value [C:\\chainsaw1.log].
In ParamAction setting parameter [Append] to value [true].
In ParamAction setting parameter [MaxFileSize] to value [1000KB].
In ParamAction setting parameter [maxBackupIndex] to value [5].
About to instantiate layout of type [org.apache.log4j.PatternLayout]
Pushing layout on top of the object stack.
No name attribute in <param> element
Popping layout from the object stack
About to set the layout of the containing appender.
setFile called: C:\test1.log, true
setFile ended
Popping appender named [RollingFile] from the object stack
Pushing root logger on stack
Encapsulating logger name is [root], levelvalue is [debug].
SocketReceiver closing server socket
root level set to DEBUG
Attaching appender named [RollingFile] to logger named [root].
Removing root logger from top of stack.
Will stop writing internal logs on console.
Finished parsing.
Using 'file:///c:/test2.xml' for auto-configuration
in run-about to enter while not interrupted loop
thanks
Paul Smith <[EMAIL PROTECTED]> wrote:
try using %d{ISO8601} instead of just %d
if this doesn't work, can you post a few lines of logs that do get
written to the 'test1.log' file?
Paul
On 21/06/2007, at 3:10 AM, akshay kumar wrote:
Hi there,
1)Is there any way that I can save the different Log-panel tab
create when I receive logs from remote machine?
Right now what happens is when I close the Chanisaw all log-panel
tab and so all logs within that get erased, which is not suitable
for my application.
Please let me know how can I do that?
2) In an alternate way to save the logs I am using rolling file
appender within the chainsaw receiver config.
But the problem in that the log file test1.log doesnt have any
timestamp information or anything else except message.
below is my config.
Please let me know what I did wrong in conversion pattern layout?
debug="true">
class="org.apache.log4j.net.SocketReceiver">
class="org.apache.log4j.RollingFileAppender">
d %-5p [%t] %C{2} (%F:%L) - %m%n" />
thanks in advance.
---------------------------------
Ready for the edge of your seat? Check out tonight's top picks on
Yahoo! TV.
Paul Smith
Core Engineering Manager
Aconex
The easy way to save time and money on your project
696 Bourke Street, Melbourne,
VIC 3000, Australia
Tel: +61 3 9240 0200 Fax: +61 3 9240 0299
Email: [EMAIL PROTECTED] www.aconex.com
This email and any attachments are intended solely for the addressee.
The contents may be privileged, confidential and/or subject to
copyright or other applicable law. No confidentiality or privilege is
lost by an erroneous transmission. If you have received this e-mail
in error, please let us know by reply e-mail and delete or destroy
this mail and all copies. If you are not the intended recipient of
this message you must not disseminate, copy or take any action in
reliance on it. The sender takes no responsibility for the effect of
this message upon the recipient's computer system.
---------------------------------
Fussy? Opinionated? Impossible to please? Perfect. Join Yahoo!'s
user panel and lay it on us.
Paul Smith
Core Engineering Manager
Aconex
The easy way to save time and money on your project
696 Bourke Street, Melbourne,
VIC 3000, Australia
Tel: +61 3 9240 0200 Fax: +61 3 9240 0299
Email: [EMAIL PROTECTED] www.aconex.com
This email and any attachments are intended solely for the addressee.
The contents may be privileged, confidential and/or subject to
copyright or other applicable law. No confidentiality or privilege is
lost by an erroneous transmission. If you have received this e-mail
in error, please let us know by reply e-mail and delete or destroy
this mail and all copies. If you are not the intended recipient of
this message you must not disseminate, copy or take any action in
reliance on it. The sender takes no responsibility for the effect of
this message upon the recipient's computer system.