Jenkins build per branch setup jobnameprefix

I’m trying to setup the following http://entagen.github.io/jenkins-build-per-branch/ plugin in Jenkins. I created a job called test_template-master and in the Switches field I put -DtemplateJobPrefix=test_ -DtemplateBranchName=master in my configuration.

When running the job now I get the following error:

getting project names from http://10.13.0.101:8080/api/json Exception
in thread “main” java.lang.AssertionError: Unable to find any jobs
matching template regex: ^(test_-[^-]*)-(master)$ You need at least
one job to match the templateJobPrefix and templateBranchName suffix
arguments. Expression: (templateJobs?.size() > 0) at
org.codehaus.groovy.runtime.InvokerHelper.assertFailed(InvokerHelper.java:388)
at
org.codehaus.groovy.runtime.ScriptBytecodeAdapter.assertFailed(ScriptBytecodeAdapter.java:658)
at
com.entagen.jenkins.JenkinsJobManager.findRequiredTemplateJobs(JenkinsJobManager.groovy:108)
at
com.entagen.jenkins.JenkinsJobManager$findRequiredTemplateJobs.callCurrent(Unknown
Source) at
org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:46)
at
org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:133)
at
org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:141)
at
com.entagen.jenkins.JenkinsJobManager.syncWithRepo(JenkinsJobManager.groovy:37)
at com.entagen.jenkins.JenkinsJobManager$syncWithRepo.call(Unknown
Source) at
org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:42)
at
org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108)
at
org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:112)
at com.entagen.jenkins.Main.main(Main.groovy:30) :syncWithRepo FAILED

So it asks for a matching templateJobPrefix and templateBranchName but I actually don’t know how I should define the JobPrefix nor the BranchName. As I defined the template job name as test_template-master I hoped it would take test_ as a prefix and master as the branch but it seems not to work like this.

Can anyone give a good example how it should work? How the job name should be defined?

Git Baby is a git and github fan, let's start git clone.