Manage Jobs in Large Scale Jenkins Installations – Archive and Delete Jobs with the Shelve Plugin

Jenkins is a great tool with it comes to continuous integration and other sorts of build automation. There is only one problem when it comes to responsiveness with a larger number of Jobs (in our case ~ 400) managed in Jenkins. When you have a larger number of jobs managed in Jenkins the startup time and also the responsiveness of the UI suffers and starting of Jenkins can easily take 15 minutes or more.

A common recommendation is to reduce the number of jobs. It is certainly a good practice to clean up your Jenkins installation and delete not needed jobs anymore. But if you need to keep your jobs for reporting, auditing or similar purposes you need a different approach. The same is true for jobs which are executed only every now and then but are otherwise idle most of the time.

Here the Jenkins Shelve Plugin come to rescue. The plugin allows you to temporarily shelve not needed jobs into an archive folder. They are then not loaded by Jenkins and improve the startup time significantly. If a job is needed later on you can easily unshelve jobs when they are needed.

But what if a job is really not needed anymore and you want to finally delete it? Up-to-now this was not possible out-of-the box. You basically had two choices. First unshelve a job and the delete the job or second delete the archive directly on the file system. Both is possible but not very user friendly, especially if you want to delete many jobs.

With the upcoming 1.5 release, the Jenkins Shelve Plugin now supports to delete archived jobs directly from the shelved project overview page (JENKINS-11374).

As you can see from the following screenshot you can now select one or more jobs and delete them by clicking on the Delete Project button.

[Update 2014-04-23]: Jenkins Shelve Plugin version 1.5 was just released (2014-04-18) and the delete feature now available.