Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-39453

xerces classcast exception when using jdk1.7_101 and multiple-scms-plugin

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      I realize the multiple-scms-plugin is deprecated, however I thought it might be useful to others to be aware of this bug.

      We recently upgraded from jenkins 2.6 to 2.28 after which the multiple-scms-plugin started throwing the exception below. We are running on ubuntu 14.04.

      Upgrading Jenkins' jdk from 1.7.0_101 to 1.8.0_111 resolved the issue (jenkins recommends 1.8 anyway).

      I don't fully understand this fix since we didn't upgrade the multiple-scms-plugin. Possibly jenkins used to ship with xerces and doesn't any more? In which case it would not be depending on the version of xerces built into the JDK. So if jdk 8's version of xerces is newer than jdk 7's then that would explain why with JDK 7 we were seeing this issue after the upgrade removed xerces from the war... this is all speculation.

      13:30:50 FATAL: org.apache.xerces.jaxp.SAXParserFactoryImpl cannot be cast to javax.xml.parsers.SAXParserFactory
      13:30:50 java.lang.ClassCastException: org.apache.xerces.jaxp.SAXParserFactoryImpl cannot be cast to javax.xml.parsers.SAXParserFactory
      13:30:50 at javax.xml.parsers.SAXParserFactory.newInstance(SAXParserFactory.java:126)
      13:30:50 at org.jenkinsci.plugins.multiplescms.MultiSCMChangeLogParser.parse(MultiSCMChangeLogParser.java:148)
      13:30:50 at hudson.model.AbstractBuild.calcChangeSet(AbstractBuild.java:911)
      13:30:50 at hudson.model.AbstractBuild.access$600(AbstractBuild.java:105)
      13:30:50 at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:616)
      13:30:50 at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86)
      13:30:50 at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:529)
      13:30:50 at hudson.model.Run.execute(Run.java:1720)
      13:30:50 at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
      13:30:50 at hudson.model.ResourceController.execute(ResourceController.java:98)
      13:30:50 at hudson.model.Executor.run(Executor.java:401)

        Attachments

          Activity

          There are no comments yet on this issue.

            People

            Assignee:
            kbell Kevin Bell
            Reporter:
            phsurette phil surette
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated: