I’m trying to retrieve a paginated list of patients by passing startIndex and limit as request params to http://{host}/{context_path}/ws/rest/v1/patient?q=something The results are very inconsistent. Passing startIndex = 1, limit = 5 returns only 2 results. Passing startIndex=1, limit=10 returns 4 results.
Aren’t v1 webservices meant to have pagination features?
Can you explain your setup a bit. What version of core and Rest Web Services are you using? If you look in the database, how many patients actually match your query? Are you using any proxy or caching server?
This is the behaviour I expect, since limit specifies how many results should be returned (see the Limiting the number of results, and paging section here).
True when number of results > limit, but the first call (limit = 5) returns 2 results. Maybe the service works fine and returns 5 results, and the resource applies a second filter ?