[ https://issues.apache.org/jira/browse/LOG4J2-3531?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17551403#comment-17551403 ]
Piotr Karwasz commented on LOG4J2-3531: --------------------------------------- Hi [~simonikula], What version of Xerces is your WebSphere using? > log4j2.xml cannot be parsed on WebSphere > ---------------------------------------- > > Key: LOG4J2-3531 > URL: https://issues.apache.org/jira/browse/LOG4J2-3531 > Project: Log4j 2 > Issue Type: Bug > Components: Configurators > Affects Versions: 2.17.2 > Reporter: Simo Nikula > Assignee: Piotr Karwasz > Priority: Minor > > Basically similar as LOG4J2-1127 > {noformat} > ERROR StatusLogger Error parsing ..log4j2.xml > javax.xml.parsers.ParserConfigurationException: Feature > 'http://apache.org/xml/features/xinclude' is not recognized. > at > org.apache.xerces.jaxp.DocumentBuilderFactoryImpl.newDocumentBuilder(Unknown > Source) > at > org.apache.logging.log4j.core.config.xml.XmlConfiguration.newDocumentBuilder(XmlConfiguration.java:193) > at > org.apache.logging.log4j.core.config.xml.XmlConfiguration.<init>(XmlConfiguration.java:91) > at > org.apache.logging.log4j.core.config.xml.XmlConfigurationFactory.getConfiguration(XmlConfigurationFactory.java:46) > at > org.apache.logging.log4j.core.config.ConfigurationFactory$Factory.getConfiguration(ConfigurationFactory.java:559) > at > org.apache.logging.log4j.core.config.ConfigurationFactory$Factory.getConfiguration(ConfigurationFactory.java:483) > at > org.apache.logging.log4j.core.config.ConfigurationFactory.getConfiguration(ConfigurationFactory.java:325) > at > org.apache.logging.log4j.core.LoggerContext.reconfigure(LoggerContext.java:690) > at > org.apache.logging.log4j.core.LoggerContext.reconfigure(LoggerContext.java:711) > at > org.apache.logging.log4j.core.LoggerContext.start(LoggerContext.java:253) > at > org.apache.logging.log4j.core.impl.Log4jContextFactory.getContext(Log4jContextFactory.java:155) > at > org.apache.logging.log4j.core.impl.Log4jContextFactory.getContext(Log4jContextFactory.java:47) > at org.apache.logging.log4j.LogManager.getContext(LogManager.java:196) > at org.apache.logging.log4j.LogManager.getLogger(LogManager.java:599) > ... > ERROR StatusLogger No logging configuration > {noformat} > Current retry does not cover this scenario. > {code:java} > final DocumentBuilder documentBuilder = newDocumentBuilder(true); > Document document; > try { > document = documentBuilder.parse(source); > } catch (final Exception e) { > // LOG4J2-1127 > final Throwable throwable = Throwables.getRootCause(e); > if (throwable instanceof UnsupportedOperationException) { > LOGGER.warn( > "The DocumentBuilder {} does not support an > operation: {}." > + "Trying again without XInclude...", > documentBuilder, e); > document = newDocumentBuilder(false).parse(source); > } else { > throw e; > } > } > {code} -- This message was sent by Atlassian Jira (v8.20.7#820007)