Hi Team,

I am using opensource *Jenkins 2.235.3* version on *Centos 7.7* machine 
with *Active Choices Plug-in Version 2.4*

The problem I am running into is very strange

I am using a groovy script to dynamically populate parameters and I am 
using Active Choices Reactive Parameter. In that plugin I have written a 
following groovy script

Groovy Code:

this.class.classLoader.addURL(new 
URL("file:///var/lib/jenkins/.groovy/grapes/org.yaml/snakeyaml/jars/snakeyaml-1.17.jar"))
def url = 'g...@xxx.xxx.com:csd/deployment.git'
def envlist = ['/bin/bash', '-c', ' ssh-add 
 /var/lib/jenkins/.ssh/id_rsa_git; cd /var/lib/jenkins/services/; git 
archive --remote='+ url +' master inventory | tar xvf -' ].execute().
envlist.waitFor()
def yaml = Class.forName("org.yaml.snakeyaml.Yaml").newInstance()
def config = yaml.load(new 
FileReader("/var/lib/jenkins/services/inventory/${SERVICES}.yml"))
return config.all.children."${SERVICES}".children.keySet()

NOTE: SERVICES is another defined parameter

Whereas when I use Active choice reactive reference parameter with same 
code:

Same groovy code works and prints out the following result
"[functional, staging_stable, pilot_stable, prod_stable]"


When I use script console in manage jenkins, it runs fine and prints me the 
same result
Result: [functional, staging_stable, pilot_stable, prod_stable]


When I check web console logs, I get 

"Calling Java server code to update HTML elements... unochoice.js:154:17 
<http://10.122.20.28:8080/adjuncts/6342f9a3/org/biouno/unochoice/stapler/unochoice/unochoice.js>
Values returned from server: [[],[]] unochoice.js:157:21 
<http://10.122.20.28:8080/adjuncts/6342f9a3/org/biouno/unochoice/stapler/unochoice/unochoice.js>


How can I proceed with debugging, I want to only use Active Choices 
Reactive Parameter?
I have attached the screenshot to show how one is populated and one is not. 
Not enough to go through and debug this problem over the internet.
Can somebody please help?

Thankyou
Nishant

-- 
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 jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/2d7253f5-79c5-4d15-b502-0f7dcdec5ce8o%40googlegroups.com.

Reply via email to