Re: Pagination (ISSUE-42)

On 02/03/2015 06:58 PM, Gregg Kellogg wrote:
> Gregg Kellogg
>> On 2015-02-03 16:31, Ruben Verborgh wrote:
>>> Hi Andrew,
>>>
>>>> In my api's and clients I much prefer to use offset and limit as a more fundamental concept to partial collections.
>>> This has strong repercussions of the cacheability of answers,
>>> which is crucial when many clients consume the API.
>>> (Graphs: http://linkeddatafragments.org/publications/iswc2014.pdf)
>>>
>> I've also disliked limit/offset endpoints because they empower users to query for very large portions of data unless the limit parameter is constrained.
> IMO, using limit/offset is natural, and expressing them as URI query parameters creates resource identifiers useful for first/last/previous/next links. In my implementations, the first page of the collection typically has no limit/offset parameters, but the rest do.
>

I fully agree to this. And yes, In case the limit is too high, I think 
the server could just responding with HTTP 416 Requested range not 
satisfiable, for example.

Received on Tuesday, 3 February 2015 22:03:01 UTC