Xldeploy plugin devloping using jython API

#1

Hi Team,

i am developing a xldeploy custom plugin to list the tasks. i am using jython API. below is the python code.

from com.xebialabs.deployit.engine.api import TaskBlockService
tasks = TaskBlockService.getAllCurrentTasks(“FULL”)

but it’s giving the error as below

getAllCurrentTasks(): expected 2 args; got 1

as per the api documentation it is having only one argument. can anybody help me on this.

API Documentation link: https://docs.xebialabs.com/jython-docs/#!/xl-deploy/7.5.x///service/com.xebialabs.deployit.engine.api.TaskBlockService

#2

what version of XLD are you working on ?

You could try:

from com.xebialabs.deployit.engine.api.execution import FetchMode

tasks = TaskBlockService.getAllCurrentTasks(FetchMode.SUMMARY)

print “The List of CurrentTasks” , tasks

#3

Hi Mzieger,

Thanks for your reply. I have tried your suggestion but still getting the same issue. I am using xldeploy 9.0.3.