Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

Get the last entry in the History section of a Testplan

Hallo,


i am able to fetch the complete history of a Testplan with this REST-API-call:
https://<my_server>/qm/service/com.ibm.rqm.integration.service.IIntegrationService/history?resourceId=resources/<my_project>/testplan/urn:com.ibm.rqm:testplan:2

I am looking for a possibility to make a request with filter option, which only retreives the last entry of the history-section.
How can this be done with REST-API or OSLC call?

1

1 vote



3 answers

Permanent link
The historyUrl is defined as a feed URL, so that means you can use the sort parameter to sort the history in date order. You could then use

https://<my_server>/qm/service/com.ibm.rqm.integration.service.IIntegrationService/history?resourceId=resources/<my_project>/testplan/urn:com.ibm.rqm:testplan:2&sort=descending

and take the first entry. You may even be able to specify the page size in the URL and make it less than the default set on the server

0 votes

Comments

The calls aren't expensive and the system sets a default page size that will ensure decent performance (by default it's 50), but the usual parameter used in ELM calls is "size" so you could try that

The calls aren't expensive and the system sets a default page size that will ensure decent performance (by default it's 50), but the usual parameter used in ELM calls is "size" so you could try that


Permanent link
Thank you for your answer.

How would I specify the page size in the URL if I only want to get for example 5 entry? 
I can't find any example for that.

0 votes


Permanent link

Good point!




_____
 

-1 votes

Your answer

Register or log in to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details
× 11,055

Question asked: Sep 15, 2:29 a.m.

Question was seen: 415 times

Last updated: Sep 25, 9:13 a.m.

Confirmation Cancel Confirm