You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-user@logging.apache.org by Stephen Pain <st...@db.com> on 2004/05/21 01:51:10 UTC

problem loading xml events to chainsaw

Hi,

Been using chainsaw v2 for a couple of days - can't get enough of it, I've introduced the rest of the team to it and we're tidying up the logging in our application to get the most benefit possible, but I'm having a problem loading xml events from a file into chainsaw...

When I try this file, for example (CTRL-O, find file in browse dialog, click OK):

<?xml version="1.0" ?>
<!DOCTYPE log4j:eventSet SYSTEM "log4j.dtd">
<log4j:eventSet xmlns:log4j="http://jakarta.apache.org/log4j/" debug="true">
<log4j:event logger="org.apache.struts.util.RequestUtils" timestamp="1085076287450" sequenceNumber="0" level="DEBUG" thread="ExecuteThread: '9' for queue: 'weblogic.kernel.Default'">
<log4j:message><![CDATA[Get module name for path /AdhocEnquiry.do]]></log4j:message>
<log4j:properties>
    <log4j:data name="log4j.remoteSourceInfo" value="longmdappd17.uk.db.com:4500"/>
    <log4j:data name="log4jid" value="1"/>
</log4j:properties>
</log4j:event>
</log4j:eventSet>

I get the following in the webstart console:

piblicID: [null]
systemId: [dummy://log4j.dtd]
log4j:ERROR Parsing error on line 1 and column -1
log4j:ERROR XML declaration may only begin entities.
org.xml.sax.SAXParseException: XML declaration may only begin entities.
      at org.apache.crimson.parser.Parser2.fatal(Unknown Source)
      at org.apache.crimson.parser.Parser2.fatal(Unknown Source)
      at org.apache.crimson.parser.Parser2.maybePI(Unknown Source)
      at org.apache.crimson.parser.Parser2.content(Unknown Source)
      at org.apache.crimson.parser.Parser2.maybeElement(Unknown Source)
      at org.apache.crimson.parser.Parser2.parseInternal(Unknown Source)
      at org.apache.crimson.parser.Parser2.parse(Unknown Source)
      at org.apache.crimson.parser.XMLReaderImpl.parse(Unknown Source)
      at org.apache.crimson.jaxp.DocumentBuilderImpl.parse(Unknown Source)
      at org.apache.log4j.xml.XMLDecoder.parse(Unknown Source)
      at org.apache.log4j.xml.XMLDecoder.decode(Unknown Source)
      at org.apache.log4j.chainsaw.FileLoadAction$2.run(Unknown Source)
      at java.lang.Thread.run(Unknown Source)
java.lang.NullPointerException
      at org.apache.log4j.chainsaw.ChainsawAppenderHandler.appendBatch(Unknown Source)
      at org.apache.log4j.chainsaw.FileLoadAction$2.run(Unknown Source)
      at java.lang.Thread.run(Unknown Source)

There are *definitely not* any blank lines/spaces/etc before the <?xml...

Can anyone help?  Although the SocketHubAppender is working really well for live monitoring, we need to be able to load an existing XMLLayout log file into chainsaw too.

Thanks in advance,

Stephen.



--

This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and destroy this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden.



---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org