Greetings, All,
I have the following script fetched from Git using Pipeline Git plugin. Unortunatelly I'm getting the following error:
org.kohsuke.stapler.NoStaplerConstructorException: There's no @DataBoundConstructor on any constructor of class org.jenkinsci.plugins.workflow.cps.steps.ParallelStep
at org.kohsuke.stapler.ClassDescriptor.loadConstructorParamNames(ClassDescriptor.java:177)
Th fetched script:import hudson.FilePath
def make_all(currentBuild){
String[] arr = getProperty("MODULES_LIST").split(",");
currentBuild.description = basic_desc
main_build = build("MAINBUILD")
buildClosures = []
for (int i=0; i<arr.length; i++) {
println "adding "+arr[i]
String tmpserv=arr[i].replaceAll("\"","")
def curClosure = {
println "Scheduling "+tmpserv.replaceAll("\"","")
retry (2) {
tmp_build = build("parrallel_test",
"MODULE": arr[i],
"MAIN_BUILD_NUM": main_build.number
)
}
tmp_build.build.artifacts.each {
//copying artifacts
}
jobs_done += 1
currentBuild.description = "Subjobs done: " + jobs_done.toString() +"/" + total_jobs.toString() + " "
}
buildClosures.add(curClosure)
}
parallel(buildClosures)
}
return this;
And the fetching script:
def factory = fileLoader.fromGit('factory.groovy',
'git_path', 'master', null, '');
factory.make_all(currentBuild)