Could this have something to do with it?
https://wiki.jenkins-ci.org/display/SECURITY/Jenkins+Security+Advisory+2016-05-11
On Friday, November 18, 2016 at 8:03:25 AM UTC-7, Eric Fetzer wrote:
> I've recently upgraded Jenkins from an older version to modern version
> (2.19.2). In the old version, my Groovy code worked well to gather the
> upstream build results. It has stopped working. I'm wondering if
> something has changed. Here is my code:
>
> import hudson.model.*
> import jenkins.model.*
>
> def resolver = Thread.currentThread().executable.buildVariableResolver
> def parent_job = resolver.resolve("upstream_job")
> def parent_build_number = resolver.resolve("upstream_bn")
> def upstreamResult = Hudson.instance.getJob("${parent_job}").getLastBuild
> ().result
> if(upstreamResult.equals(hudson.model.Result.FAILURE)) {
> upstreamResult = "fail"
> } else {
> upstreamResult = "${upstreamResult}".toLowerCase()
> }
> println "upstream result: ${upstreamResult}"
> def newParams = null
> def pl = new ArrayList<StringParameterValue>()
> pl.add(new StringParameterValue('build_result', upstreamResult))
> def oldParams = build.getAction(ParametersAction.class)
> if(oldParams != null) {
> newParams = oldParams.createUpdated(pl)
> build.actions.remove(oldParams)
> } else {
> newParams = new ParametersAction(pl)
> }
> build.addAction(newParams)
>
>
> Thanks,
> Eric
>
--
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/572938e4-e069-4e51-9173-9ffbd8e0d866%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.