1
votes

I just set up a vanilla Jenkins (ver. 1.634) instance in EC2 and followed the tutorial for getting the workflow plugin installed. That all worked as expected.

Now I'd like to move on to trying out the multi-branch portion of this plugin. I noticed the tutorial says:

A new Workflow: Multibranch plugin (as of this writing still in beta) offers a better way of versioning your Workflow and managing your project. You need to create a distinct project type, Multibranch Workflow.

First Attempt

Which I took to mean that this plugin doesn't exist at http://updates.jenkins-ci.org/update-center.json but rather some other update center. So after some searching, I wound up on this Jenkins page and changed the update center to http://updates.jenkins-ci.org/experimental/update-center.json After looking at the new set of available plugins, the Workflow: Multibranch plugin was still absent.

Second Attempt

I then proceeded to try packaging the plugin myself by cloning jenkinsci/workflow-plugin repo and running mvn package from the multibranch directory which gave me the workflow-multibranch.hpi plugin that I had been trying to find via the update site. Next, I attempted to install the plugin manually Jenkins -> PluginManager -> Advanced (Tab) -> Upload Plugin.

Jenkins presented me with the following error:

java.io.IOException: Failed to dynamically deploy this plugin
  at hudson.model.UpdateCenter$InstallationJob._run(UpdateCenter.java:1328)
  at hudson.model.UpdateCenter$DownloadJob.run(UpdateCenter.java:1126)
  at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
  at java.util.concurrent.FutureTask.run(FutureTask.java:262)
  at hudson.remoting.AtmostOneThreadExecutor$Worker.run(AtmostOneThreadExecutor.java:110)
  at java.lang.Thread.run(Thread.java:745)
Caused by: java.io.IOException: Failed to install workflow-multibranch plugin
  at hudson.PluginManager.dynamicLoad(PluginManager.java:487)
  at hudson.model.UpdateCenter$InstallationJob._run(UpdateCenter.java:1324)
  ... 5 more
Caused by: java.io.IOException: Dependency workflow-job (1.11-beta-1), branch-api (0.2-beta-5), workflow-cps (1.11-beta-1) doesn't exist
  at hudson.PluginWrapper.resolvePluginDependencies(PluginWrapper.java:533)
  at hudson.PluginManager.dynamicLoad(PluginManager.java:477)
  ... 6 more

Now, before I end up making a mess of my plugins by manually installing all of these dependent plugins listed in the stacktrace, is there a more direct way to install the Workflow: Multibranch plugin?

Thanks.

2

2 Answers

1
votes

You were correct to set the experimental update center, but

After looking at the new set of available plugins, the Workflow: Multibranch plugin was still absent.

probably just means that you needed to click the Update Now button in the Advanced tab to actually fetch the new update center content.

0
votes

I ended up installing the plugins one at a time until I found a rather odd dependency, Cloudbees. After looking through the list of Jenkins plugins for Cloudbees I found the plugin required to make Workflow: Multibranch appear in the list of available plugins.

CloudBees Free Enterprise Plugins This plugin installs free enterprise plugins from CloudBees. The following plugins are automatically installed: Folders: easily organize your jobs Backup to Cloud: backup your Jenkins into CloudBees cloud Wasted Minutes: find out if you are short of slaves and need to add capacity to speed up builds CloudBees Status: find out how much of the free CloudBees Jenkins capacity in the cloud is available for your use Note: You will be asked to register for a free CloudBees account to use these plugins (This plugin was formerly known as the CloudBees Plugin Gateway plugin)

Once this plugin was installed and I restarted Jenkins then I was able to install Workflow: Multibranch. Additionally, all of the other Workflow: * plugins had updates available.

Hope this saves someone the hours I spent.