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

The REST API is running much slower than expected

I wrote a little tool to query RTC through the REST API. Here is the syntax of the HTTP command being sent:

https://SERVER:PORT/jazz/rpt/repository/workitem?fields=workitem/workItem[projectArea/name='PROJECTNAME' and category/name='CATEGORYNAME' and target/name='ITERATIONNAME']/(id|itemId|summary|target/name|category/name|projectArea/name|modified|modifiedBy/name|type/name|owner/name|duration|timeSpent|state/(name|group)|itemHistory/(summary|target/name|category/name|projectArea/name|modified|modifiedBy/name|type/name|owner/name|duration|timeSpent|state/(name|group)|description))&size=999

I also tried substituting the name fields for itemId fields, for example:

[projectArea/itemId='_weudbrw83452934' and category/itemId='_78rehrgh8ddfhske' and target/itemId='_i345h3ih53i4']                        (made up numbers for this example)

If anything, that took longer.

The query takes about 45 seconds to run. Of course if I pull up a query through the web client directly instead of using the API, it comes up in 2 seconds. Is there some other way of doing queries through the API that is faster? Perhaps using the OSLC syntax?

1

0 votes



One answer

Permanent link
I found a faster way to do work item queries via OSLC:

https://SERVER:PORT/jazz/oslc/contexts/_IIGX4ImSEeGfRoNJQk-wkQ/workitems?oslc_cm.pageSize=100&oslc_cm.query=rtc_cm:plannedFor="_ZypC8IX5EeKO39ytcjC0xQ" and rtc_cm:filedAgainst="_nR9kIImYEeGfRoNJQk-wkQ"

HOWEVER... that query does not get me history data and the whole point of creating this tool was to get easy access to history data. So... is there a way to get history data via OSLC (without having to query each Work Item separately)?

Note: The OSLC method needs to be paginated. If you set page size much higher than 100 you get "query expired" errors. Still takes a lot less time to run than the method in the original post.

2 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
× 10,930
× 515
× 478

Question asked: Aug 16 '13, 1:28 p.m.

Question was seen: 6,374 times

Last updated: Aug 21 '13, 7:35 p.m.

Confirmation Cancel Confirm