Multi-configuration project fails to load after Jenkins 2 upgrade

200 views
Skip to first unread message

Gavin Williams

unread,
Aug 19, 2016, 12:21:44 PM8/19/16
to Jenkins Users
Afternoon all

I've just upgraded one of our Jenkins hosts from 1.6 to 2.18, and unfortunately it appears to have broken some of our Multi-configuration projects. 

Upon restarting Jenkins, the following is logged:
SEVERE: Failed Loading job Microservice_Matrix_Unit
java.lang.NullPointerException
        at hudson.matrix.MatrixProject.createTransientActions(MatrixProject.java:450)
        at hudson.model.AbstractProject.updateTransientActions(AbstractProject.java:756)
        at hudson.matrix.MatrixProject.updateTransientActions(MatrixProject.java:460)
        at hudson.model.AbstractProject.onLoad(AbstractProject.java:340)
        at hudson.matrix.MatrixProject.onLoad(MatrixProject.java:501)
        at hudson.model.Items.load(Items.java:333)
        at jenkins.model.Jenkins$17.run(Jenkins.java:2942)
        at org.jvnet.hudson.reactor.TaskGraphBuilder$TaskImpl.run(TaskGraphBuilder.java:169)
        at org.jvnet.hudson.reactor.Reactor.runTask(Reactor.java:282)
        at jenkins.model.Jenkins$7.runTask(Jenkins.java:1026)
        at org.jvnet.hudson.reactor.Reactor$2.run(Reactor.java:210)
        at org.jvnet.hudson.reactor.Reactor$Node.run(Reactor.java:117)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
        at java.lang.Thread.run(Thread.java:745)

I've not found anything of any use whilst googling... 

Any ideas on how I can fix the jobs?

Regards
Gavin  

Gavin Williams

unread,
Aug 23, 2016, 7:54:45 AM8/23/16
to Jenkins Users
Just to confirm, I hit exactly the same error on a fresh Jenkins 2 installation... 

Anyone hit anything similar?

Cheers
Gavin 

Daniel Beck

unread,
Aug 23, 2016, 8:01:05 AM8/23/16
to jenkins...@googlegroups.com
What versions of Jenkins and the Matrix Project plugin is this?
> --
> You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-use...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/28dbe048-73e8-43e2-b9fe-7b98e0bf2703%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

Gavin Williams

unread,
Aug 23, 2016, 9:37:44 AM8/23/16
to Jenkins Users, m...@beckweb.net
The latest occurrence on a fresh install with latest of everything is:
* Jenkins: 2.7.2
* Matrix Project plugin: 1.7.1

Cheers
Gavin 

Daniel Beck

unread,
Aug 23, 2016, 11:03:38 AM8/23/16
to jenkins...@googlegroups.com
Please provide the config.xml of the affected job. It seems to be invalid.

Maybe a plugin is failing to load. Anything in the logs, or on /manage?
> To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/5b833923-593d-4817-8f1b-85ad187f6722%40googlegroups.com.

Gavin Williams

unread,
Aug 23, 2016, 11:20:36 AM8/23/16
to Jenkins Users, m...@beckweb.net
Daniel


Nothing obvious in the logs, and some complaints about 'Unreadable Data'. 
A couple of lines corresponding to this project:
hudson.model.FreeStyleProjectUnit_4NoSuchMethodError: org.jruby.RubyClass.getVariableAccessorForWrite(Ljava/lang/String;)Lorg/jruby/RubyClass$VariableAccessor;, InstantiationError: null, MissingFieldException: No field 'pluginid' found in class 'hudson.model.FreeStyleProject'
hudson.model.FreeStyleProjectUnit_4NoSuchMethodError: org.jruby.RubyClass.getVariableAccessorForWrite(Ljava/lang/String;)Lorg/jruby/RubyClass$VariableAccessor;, InstantiationError: null, MissingFieldException: No field 'pluginid' found in class 'hudson.model.FreeStyleProject'

From a plugins POV, I'm using:
* RVM
* Build Name Setter
* EnvInjector
* Git

Plus a few others that probably aren't relevant.. 

Cheers
Gavin 

Gavin Williams

unread,
Aug 23, 2016, 11:22:58 AM8/23/16
to Jenkins Users, m...@beckweb.net
Ah, actually, apologies, I got this issue mixed up with another one I'm currently having... 

Yes, there is an error in the logs for the Multi-Configuration project. 

Aug 23, 2016 3:59:58 PM jenkins.InitReactorRunner$1 onTaskFailed

SEVERE: Failed Loading job Microservice_Matrix_Unit
java.lang.NullPointerException
        at hudson.matrix.MatrixProject.createTransientActions(MatrixProject.java:450)
        at hudson.model.AbstractProject.updateTransientActions(AbstractProject.java:755)
        at hudson.matrix.MatrixProject.updateTransientActions(MatrixProject.java:460)
        at hudson.model.AbstractProject.onLoad(AbstractProject.java:339)

        at hudson.matrix.MatrixProject.onLoad(MatrixProject.java:501)
        at hudson.model.Items.load(Items.java:333)
        at jenkins.model.Jenkins$17.run(Jenkins.java:2823)

        at org.jvnet.hudson.reactor.TaskGraphBuilder$TaskImpl.run(TaskGraphBuilder.java:169)
        at org.jvnet.hudson.reactor.Reactor.runTask(Reactor.java:282)
        at jenkins.model.Jenkins$7.runTask(Jenkins.java:998)

        at org.jvnet.hudson.reactor.Reactor$2.run(Reactor.java:210)
        at org.jvnet.hudson.reactor.Reactor$Node.run(Reactor.java:117)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
        at java.lang.Thread.run(Thread.java:745)

I've just ditched the Project config unfortunately though, so let me see if I can re-create... 

Cheers
Gavin  
Message has been deleted

Daniel Pflager

unread,
Sep 8, 2016, 6:36:59 PM9/8/16
to Jenkins Users
We had something similar. Jenkins 2.7.3. After some experimentation, I found that adding the empty tag:

<buildWrappers/>

right before the executionStrategy tag at the end of the config.xml, like this:

.
.
.
  <buildWrappers/>
  <executionStrategy class="hudson.matrix.DefaultMatrixExecutionStrategyImpl">
    <runSequentially>false</runSequentially>
  </executionStrategy>
</matrix-project>

and then reloading configuration from disk fixed the problem. The matrix job now loaded.
Reply all
Reply to author
Forward
0 new messages