skipCount argument for REST call to
does not appear to work correctly. From reading the [http://docs.alfresco.com/4.2/pra/1/concepts/pra-pagination.html|Pagination] help, skipCount should skip the first n results from the totalItems amount and return the next page (or up to maxItems). The problem appears to be that skipCount is always referring to the original page results, not to the totalItems.
Say, we have 1050 tasks assigned to a group and we are querying using a few clauses, thus slowing the query down and forcing pagination:
http://localhost:8080/alfresco/api/-default-/public/workflow/versions/1/tasks?skipCount=0&maxItems=2000&where=(candidateUser = 'admin' AND status = 'active' AND includeTaskVariables = 'true' AND includeProcessVariables = 'true')
From what I understand of the docs, setting skipCount to 625 in a follow-up query would get either all of the remaining results or the next page (depending on the speed of the query). However it appears that skipCount currently refers to the totalItems, therefore changing the skipCount to 625 in this case returns zero results, i.e.
1. Create ~1050 workflow tasks
1a. Upload a document to the repository and get it's nodeRef
2. Once that completes run the following REST call from a browser:
At this point, it should page the first set of results, in my environment, I get 625 returned, i.e.
3. Change the query's skipCount to 625 for example (or whatever the total of the returned number was previously) and send the call again.
Call should skip the first paged set and return the next page (or the rest of the results)
The first page is returned again minus the skipCount.