qos-ch / reload4j

reload4j is a drop-in replacement for log4j 1.2.17
Apache License 2.0
148 stars 22 forks source link

Missing setFeature function in DocumentBuilderFactory #34

Closed ceki closed 2 years ago

ceki commented 2 years ago

Certain older DocumentBuilderFactory implementations lack the setFeature function. This causes an AbstractMethodError method to be thrown in org.apache.log4j.xml.DOMConfigurator.doConfigure(ParseAction, LoggerRepository)

Instead of letting the user identify the issue, better to catch and report this

ceki commented 2 years ago

Fixed in 98e380decc741e0e

ppkarwasz commented 1 year ago

@ceki, I believe that for backward compatibility the setFeature calls should be in their own try ... catch. A missing setFeature() method or support for the required features should not cause a parsing error, just a warning.