On Oct 30, 2012, at 5:53 PM, Matthias Wessendorf wrote:
Hello!
On Tue, Oct 30, 2012 at 10:44 PM, Douglas Campos <qmx@qmx.me> wrote:
Howdy!
As we discussed on our team meeting today, having basic query and pagination support would be cool.
Here are some suggestions, gathered from previous conversations around the topic, and from some BaaS providers in the wild.
Paging:
1) /cars/?limit=10&offset=3
2) /cars/?limit=10&skip=3
Is the skip the number of pages, or the literal item count to start on?
Also, we would want a way to get back a total #, and page #'s give a page size. This may be a separate call - wdyt?
Query:
1) /cars/query?color=blue
2) /cars/?query={"color":"red", "owner":"summers"}
3) /cars/?where={"brand":"BMW"}
4) /cars/?query={"engine":{"cylinders": 8}}
5) /cars/?query={"engine":{"cylinders":{"$gt":6}}}
This is not set into stone, just ideas,
I guess it's a matter of agreeing :) the main work is on the "ag
server component".
Question.... do we want to keep it flexible? E.g. if AG clients are
used for a backend that does not use "limit" for the pagination?
(I guess kinda similar to what we have on the endpoints, where you can
override the default)
Where would you override this? In the pipeline creation?
This would allow future nesting of queries.
and I do think that anything above exact matches should go after 1.0
fine w/ me
+1