-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Next, Prev, First, Last in AnnotationCollection/AnnotationPage #371
Comments
Typically, but not in this case. From the protocol spec, section 4.2:
We started off with the typical offset/limit pattern but decided against it for the following reasons:
So ... as this has been discussed, unless there is some new information that makes the current approach un-implementable (which would be strange, considering there are implementations), or some significant benefit that was overlooked in the original discussion, I propose close wontfix. |
Yes, I do agree with what you say, this is still an open issue, and with this ticket I want to raise awarness of it. My concern and may claim is that individual pages are considered to be resources, consequently accessing the URIs/IRIs of these resources must return the same content at different points in time and by different users (possibly using additional request parameters.) In practice, this will not the case, becasue I expect that the most of the implementations will have requirements to use the pageSize. Almost all existing json based APIs are implementing like that. Offset+Limit is an equivalent representation to PageNr + PageSize... so we are talking about the same thing. And my point is that the current specifications are incomplete in this aspect. The page number is a unique identifier of the Page resource only in the case that the server doesn't allow the user to set the page size in their request. Concretely, we cannot say that the following resources are the same or even equivalent. Also .. we can say that these are actually different resources as they have different URIs, that would be also fine, only that the current specifications doesn't mentions something like that. In this case, we have annother thing that is not clear. Given that the default pageSize used by implementation is 10. How can we indicate that the following resources are the same? If you don't wont to solve this issue in V1 is ok for me... but I think we should recognize this as being an open issue |
|
(admin comment) @gsergiu, I have the impression that what you want to change is not editorial but substantial. At this point, with (as we plan) only a few weeks away from a PR transition, any substantial change would seriously set back the progress of the work (restarting CR, etc). Of course, it there was a really serious technical issue then we would have no choice, but I do not have the impression it is the case. I would propose to:
You did hint at this possibility; do you agree for me to proceed? |
@iherman BR, |
PS: as general comment/strategy I find more appropriate to postpone the open/known issues that cannot be solved within the scope of V1/PR. I do not support of closing tickets as "won't fix" (in V1) as long as the issues are not actually solved. (Open Issues for V2, and the discussions within these issues are still valuable information for implementors) |
This is an impossible requirement that we should not attempt to solve. A trivial example that would break this: Delete the first annotation from the first page. Now every annotation shifts up one position, and every page's representation changes. Caching is not just an implementation concern, it's a concern for any practical web standard. If the client has control of the page size, then the server needs to cache all possible sets of pages. That's while not impossible, completely impractical. If it's all just an implementation concern ... then feel free to add your own pagesize parameter. No need to standardize. If it's not, then you need to actually address the questions. |
|
👎 to adding anything with regard to page size. This is far to idiosyncratic, implementation specific, and not necessary for interoperability--and would in fact inhibit it. It should be noted that existing feed/collection/syndication formats (RSS, Atom, ActivityStreams) do not attempt this--nor should we here. Our pagination vocabulary is from ActivityStreams 2.0. They do not (nor should they) attempt to specify page size as it only inhibits interoperability and unnecessarily raises the bar of implementation. |
Ok ... it seems that you consider only the case that the client is not allowed to set by itself the number of items included in a page. This is a standard functionality in most CMS systems, and in json apis. I assumed that it would be benefic to include it in the WA specifications as well. It seems that the tendency is to let this decision to the implementations. I assume than the solution would be to eliminate the page size in the URIs when the default page size is used, and keep it in the URIs otherwise. I'm not sure if there is a possiblity to document this in some non normative document or ... in the "primer" document that was recommended in some older tickets. BR, |
@gsergiu everyone is likely (and does) do it different, and as such, it's not really necessary for us to give pointers--even non-normative ones--about how one might do it. If one needs it, one does it. Given that the feed formats mentioned earlier haven't addressed the issue (and likely avoided it), I don't think we should venture in "where angels fear to tread." |
I just find this to be useful information for implementers, even if there is no recommendation of how to deal with. |
The Next, prev, First, Last are specified as being IRIs, consequnetly, these means that different requests to the same IRI should return the same annotations.
However, the number of annotations included in a page is not specified in the WA standard, and typically this is an (implementation specific) request paramenter as it can be found also in the jsonapi specifications (where is still looks to be an open issue):
http://jsonapi.org/format/1.1/#fetching-pagination
I would recommended including the pageSize paramenter within the IRIs indicating the next, prev, first, last properties.
This is a followup ticket for the #233 which was mainly focusing on the existance of the properties, but not on the verification of the annotations included in these resources.
The text was updated successfully, but these errors were encountered: