Groovy to get all the jobid's running under pipeline
Summary:
Hi Experts,
We are exploring how to get all job's under running parent pipeline job For example
- Pipeline has 4 dlrs , want to get job'id of each process using Json loop then print subsequently dat files and log files
abcplan_rtg_1233.dat
abcplan_rtg_1234.dat
/outbox/log/abcplan_rtg_1234.log
Currently , able to get pipeline Job id using groovy get method but unable to get all jobids under pipeline
Sample script
for(long delay = 50; status == IN_PROGRESS; delay = Math.min(1000, delay * 2)) {
sleep(delay)
xxxxResponse = operation.application.getConnection("xxxxxxx").get("/aif/rest/V1/xxxxxxx/" + jobId).asString()
status = JsonPath.parse(xxxxxResponse.body).read('$.status')
Tagged:
0