[closed] RTC returns only 50 work items when it is accessed though OSLC query
I wanted to change the number of records returned from RTC server when it is accessed via OSLC. It seems default value is 50. So I added oslc.paging and oslc.pageSize.
https://localhost/ccm/oslc/contexts/<project_uuid>/workitems?oslc.paging=true&oslc.pageSize=200&oslc.select=dcterms:identifier
But still it returns only 50 records. if I change the value to oslc.pageSize=10, the query returned 10 records. So this parameter is working for less than 50. I did some experiments:
- oslc.pageSize=10 => Works
- oslc.pageSize=50 => Works
- oslc.pageSize=100 => Works
-
oslc.pageSize=101 => Does not Work !
I wonder if this is a spec or bug. I prefer not to use oslc:nextPage ( I understand there is overhead in the client side for large query though).
The question has been closed for the following reason: "The question is answered, right answer was accepted" by rschoon Jul 13 '23, 1:27 p.m.
Accepted answer
4 other answers
Just to add a note to this thread, I believe you can override the default number of query results by adding an optional qualifier at the end of the URL. I've done this with REST API queries and not really with the OSLC ones, but I assume it works for both protocols. Just tack on "&size=###" to override the number of returned results.
For example:
Setting oslc.pageSize over 100 does not work when querying workitems through OSLC (228310)
Please use this workitem when users hit this problem.
Comments
I think IBM uses paging as a defensive measure against a client dragging out the entire data set and clobbering the server. Been barking up this tree for some time and gave up. Now I have a small set of logic that looks for next page and iteratively calls the server for the next batch of material, appending it to a big list (in perl) as we go.
Yes, that is what I'm doing now in my Perl module. It is not difficult.
This is an old post, but I don't see resolution. The setting mentioned by Prasun I cannot find in EWM (version 7.0.2).