logging-log4j-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 49471] Add CDATA parameter to XmlLayout
Date Thu, 18 Nov 2010 00:37:44 GMT

--- Comment #4 from mattgerlitz@msn.com 2010-11-17 19:37:40 EST ---
(In reply to comment #3)
> Anything handling XML input should accept use of CDATA sections.  If you are
> using a DOM implementation and want to simplify your code, you can configure
> the parser not to preserve CDATA sections.

If I remove the CDATA sections then I lose the information I want. The issue is
the message I want to log IS xml. The idea being I can extract information in
the log file via XPATH. 

To accomplish this I gave up on the the XmlLayout and just used a PatternLayout
with value="%m" to log the message (the message, again, is a xml fragment).
Then for post processing I just wrapped the messages with a root element and
preformed the xslt and xpath. I had to add my own timestamp within the message
but it works.

Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

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

View raw message