I have recently upgraded the Jenkins version from 2.319.2 to 2.346.2.
Post that my builds are failing at “def files = new FileNameFinder().getFileNames(env.WORKSPACE,‘*/.war *//.war */.ear *//.ear’);”.
if I restart my Jenkins and trigger the same job it gets success, however, if I retrigger the same job again it gets fails. Each time I restart Jenkins it gets success only once.
Error:
java.lang.ClassCastException: class org.apache.xerces.parsers.XIncludeAwareParserConfiguration cannot be cast to class org.apache.xerces.xni.parser.XMLParserConfiguration (org.apache.xerces.parsers.XIncludeAwareParserConfiguration is in unnamed module of loader org.jenkinsci.plugins.workflow.cps.CpsGroovyShell$CleanGroovyClassLoader @49cc49d9; org.apache.xerces.xni.parser.XMLParserConfiguration is in unnamed module of loader org.jenkinsci.plugins.workflow.cps.CpsGroovyShell$CleanGroovyClassLoader @6d07455b)