java.lang.ClassCastException: hudson.maven.MavenModuleSetBuild cannot be cast to hudson.model.Build

Jenkins JIRA | Dominik Bartholdi | 3 years ago
  1. 0

    Problem checking out (from VSS) and building maven project in Hudson

    Stack Overflow | 8 years ago | Petr Macek
    java.lang.ClassCastException: hudson.maven.MavenModuleSetBuild cannot be cast to hudson.model.Build
  2. Speed up your debug routine!

    Automated exception search integrated into your IDE

  3. 0

    As you can see below, it doesn't show the call site information. {noformat} ERROR: Processing failed due to a bug in the code. Please report this to jenkins-users@googlegroups.com java.lang.ClassCastException: cannot assign instance of hudson.model.StreamBuildListener to field hudson.maven.MavenModuleSetBuild$PomParser.listener of type hudson.model.BuildListener in instance of hudson.maven.MavenModuleSetBuild$PomParser at java.io.ObjectStreamClass$FieldReflector.setObjFieldValues(ObjectStreamClass.java:2056) at java.io.ObjectStreamClass.setObjFieldValues(ObjectStreamClass.java:1229) at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1969) at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1887) at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1770) at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1346) at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1963) at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1887) at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1770) at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1346) at java.io.ObjectInputStream.readObject(ObjectInputStream.java:368) at hudson.remoting.UserRequest.deserialize(UserRequest.java:178) at hudson.remoting.UserRequest.perform(UserRequest.java:98) at hudson.remoting.UserRequest.perform(UserRequest.java:48) at hudson.remoting.Request$2.run(Request.java:270) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334) at java.util.concurrent.FutureTask.run(FutureTask.java:166) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) at java.lang.Thread.run(Thread.java:636) {noformat}

    Jenkins JIRA | 6 years ago | Kohsuke Kawaguchi
    java.lang.ClassCastException: cannot assign instance of hudson.model.StreamBuildListener to field hudson.maven.MavenModuleSetBuild$PomParser.listener of type hudson.model.BuildListener in instance of hudson.maven.MavenModuleSetBuild$PomParser

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.ClassCastException

      hudson.maven.MavenModuleSetBuild cannot be cast to hudson.model.Build

      at com.tikal.jenkins.plugins.multijob.MultiJobBuilder$SubJobWorker.run()
    2. com.tikal.jenkins
      MultiJobBuilder$SubJobWorker.run
      1. com.tikal.jenkins.plugins.multijob.MultiJobBuilder$SubJobWorker.run(MultiJobBuilder.java:199)
      1 frame
    3. Java RT
      Thread.run
      1. java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      2. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      3. java.lang.Thread.run(Thread.java:724)
      3 frames