You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-dev@logging.apache.org by bu...@apache.org on 2009/07/23 10:17:45 UTC

DO NOT REPLY [Bug 47560] New: log4j.xml parse error

https://issues.apache.org/bugzilla/show_bug.cgi?id=47560

           Summary: log4j.xml parse error
           Product: Log4j
           Version: 1.2
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Configurator
        AssignedTo: log4j-dev@logging.apache.org
        ReportedBy: sdimitrijevic@dirkzwager.com


I use log.xml with log4j1.2.15 and I ge the following error.
log4j:WARN Fatal parsing error 43 and column 6
log4j:WARN The processing instruction target matching "[xX][mM][lL]" is not
allowed.
log4j:ERROR Could not parse url
[file:/C:/Program%20Files/Sonic/Workbench7.6/workspace/Sonic_LoggingServices/conf/log4j.xml].
org.xml.sax.SAXParseException: The processing instruction target matching
"[xX][mM][lL]" is not allowed.
    at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
    at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
    at javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:146)
    at org.apache.log4j.xml.DOMConfigurator$2.parse(DOMConfigurator.java:690)
    at
org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.java:789)
    at
org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.java:696)
    at
org.apache.log4j.helpers.OptionConverter.selectAndConfigure(OptionConverter.java:471)
    at org.apache.log4j.LogManager.<clinit>(LogManager.java:125)
    at org.apache.log4j.Logger.getLogger(Logger.java:105)
    at
com.dirkzwager.mediation.logging.test.dao.ESBLoggerAccessorDaoMainTest.<clinit>(ESBLoggerAccessorDaoMainTest.java:8)
log4j:WARN No appenders could be found for logger
(org.springframework.util.ClassUtils).
log4j:WARN Please initialize the log4j system properly.

Can you tell me what I doe wrongly?

-- 
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


DO NOT REPLY [Bug 47560] log4j.xml parse error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=47560


Curt Arnold <ca...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |INVALID




--- Comment #1 from Curt Arnold <ca...@apache.org>  2009-07-23 06:28:01 PST ---
Please ask usage questions on log4j-user@logging.apache.org.

The message suggests that you have a processing instruction with the tag XML,
xml or some variation at column 6 (maybe line 43) in the file
file:/C:/Program%20Files/Sonic/Workbench7.6/workspace/Sonic_LoggingServices/conf/log4j.xml.

A processing instruction is an XML construct that looks like:

<?tag unstructured stuff?>

The XML declaration looks like a processing instruction, but must occur as the
very first content of an XML document or other parsed entity.

<?xml encoding="..." version="..."?>

The error is due to having either an XML declaration at the wrong place in the
document or having a processing instruction that uses an prohibited name.  The
underlying XML parser is required to treat that as an error.

-- 
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