Hello Paul,
Thank you for responding.
Yes, I am using log4j1.2.9; no, I am not specifying
LocationInfo.
And, guess what? In the meantime I found a mailing list response
from Scott Deboy that solved my problem. The SocketAppender may not
specify layout information. When I removed the Layout element from my
configuration (see my original post) it began to work. Hurray!
Also, as you said and/or hinted at, due to an existing problem,
the SocketAppender should not set LocationInfo=true and should be added
ahead of any other appender that uses location information:
<root>
<priority value="debug"/>
<appender-ref ref="Socket"/> <!-- First, no location info -->
<appender-ref ref="Console"/> <!-- May specify location info -->
<appender-ref ref="RollingFile"/> <!-- May specify location info -->
</root>
Again, thanks for caring!
Best Regards,
Robert Vaessen
-----Original Message-----
From: Paul Smith [mailto:[EMAIL PROTECTED]
Sent: Sunday, February 27, 2005 3:52 PM
To: Log4J Users List
Subject: Re: Difficulty using Chainsaw SocketReceiver
Is Chainsaw v2 'talking' with a log4j1.2.x version? If it is, first
ensure that the 1.2.x setup does not output LocationInfo to ANY other
appender, because there is some serialization incompatability between
log4j1.2.x and log4j1.3 that Chainswaw v2 uses.
There is a way to get them both to work, but lets try removing that
first to get you going.
cheers,
Paul Smith
Robert Vaessen wrote:
>Hello,
>
>
>
>I tried real hard (google, mail archives) not to post this message.
>Please forgive any "stupidity".
>
>
>
>I am logging messages using a SocketAppender. If I use the Chainsaw
that
>is "bundled" with log4j I see my messages. If I use Chainsaw V2 then I
>only see the "housekeeping" messages that are produced by the
>SocketReceiver when the connections are made; I never see my message.
>
>
>
>Here is my client side log4j configuration:
>
><?xml version="1.0" encoding="UTF-8"?>
>
><!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>
><log4j:configuration debug="true"
>xmlns:log4j="http://jakarta.apache.org/log4j/">
>
> <appender name="Socket"
>class="org.apache.log4j.net.SocketAppender">
>
> <param name="RemoteHost" value="localhost"/>
>
> <param name="Port" value="4560"/>
>
> <layout class="org.apache.log4j.PatternLayout">
>
> <param name="ConversionPattern" value="%t
>%-5p %c{2} - %m%n"/>
>
> </layout>
>
> </appender>
>
> <root>
>
> <priority value="debug"/>
>
> <appender-ref ref="Socket"/>
>
> </root>
>
></log4j:configuration>
>
>
>
>Here is the command that I use to start the bundled Chainsaw:
>
>start javaw -cp <MyPath>\log4j-1.2.9.jar -Dchainsaw.port=4560
>org.apache.log4j.chainsaw.Main
>
>
>
>The "new" Chainsaw, which I obtain via java webstart, reports its
>version as "Chainsaw 2.0alpha". When I run it I am given the
opportunity
>to create a Simple Socket Receiver. I do so, specifying a port number
of
>4560.
>
>
>
>Would someone please advise me? Also, feedback on whether or not I
>successfully posted this message as "text only" will be welcome.
>
>
>
>Best Regards,
>
>Robert Vaessen
>
>
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]