Hi,
I'm writing a pipeline groovy script. and stumbled upon this problem:
If I try to run step within a function, then function is immediately
terminated and doesn't execute following instructions.
I.e.
I have function:
@NonCPS
def getBuildOutput(build_job) {
echo "BeforeStep"
def prop_file=readFile('get_src_job_artifacts/output.properties')
echo "AfterStep"
//Execute further processing with non serializable variables
//....
But when I call it, "BeforeStep" is echoed, but "AfterStep" is not.
instead getBuildOutput returns string read from that file.
Why is that, and is there a way to avoid that?
--
You received this message because you are subscribed to the Google Groups
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/jenkinsci-users/db7d0d57-406b-474e-8022-8182578e897c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.