rundeck / rundeck-api-java-client

Java client for the Rundeck REST API
http://rundeck.github.com/rundeck-api-java-client
Apache License 2.0
13 stars 17 forks source link

Fix getExecutions not working with api v11 #12

Closed Sylvain-Bugat closed 10 years ago

Sylvain-Bugat commented 10 years ago

Results return by an API call when calling getExecutions(ExecutionQuery query, Long max, Long offset) in the RundeckClient class is still the same in v11 api:

<result success="true" apiversion="11"> <executions count="10" total="20" offset="0" max="10"> <execution id="251" href="http://localhost:4440/execution/follow/251" status="failed" project="test"> ... </execution> </executions> </result>

But the rootXpath() to get the root xpath for parsing result return an empty string when using v11 api or upper. For this call i think the result root is needed (tested with Rundeck 2.1.2 and v11 api)

gschueler commented 10 years ago

this may be a bug in the rundeck API, for API v11 it shouldn't include the <result> element

gschueler commented 10 years ago

thanks for the pull request, added more extensive fix in #17