Wednesday, 2 January 2019

Jenkins: How to use SVN Checkout Strategies with Multibranch pipelines

Recently, we had the problem that we moved large SVN repositories to Jenkins multibranch pipelines.

There, a typical checkout looks like this:

Here, the issue is that there is always a fresh checkout performed. This can take a very long time for larger repositories. The SVN Multibranch pipeline lacks the possibility to define the checkout strategy that could be definen in the old way, or when working with simple pipeline scripts.

The solution is to manipulate the scm object, that is present in the multibranch pipeline:

You can also do other things with the scm object, for example make the output quiet: