fedora-infra / bodhi

Bodhi is a web-system that facilitates the process of publishing updates for a Fedora-based software distribution.
https://bodhi.fedoraproject.org
GNU General Public License v2.0
152 stars 195 forks source link

Query API #14

Closed lmacken closed 10 years ago

lmacken commented 11 years ago

We need to port & improve the query API to ensure that it allows users to query updates & buildroot overrides appropriately.

An example of one of the issues we're having with the current API is that certain parameters, like 'bugs' and 'date_modified', are mutually exclusive.

lmacken commented 11 years ago

We also need pagination support.

WebHelpers provides a nice API that will integrate nicely with our SQLAlchemy & WebOb setup: http://docs.pylonsproject.org/projects/webhelpers/en/latest/modules/paginate.html

bochecha commented 11 years ago

We've done a fair bit of this during Flock. The current Git HEAD can return updates filtered by:

None are mutually exclusive, the filters can all be combined as desired. Adding filters just AND-s them.

@giallu has started working on filters on other dates:

Compared to Bodhi 1, we're still missing update filters by:

bochecha commented 11 years ago

So if you merge pull requests #20 and #21, we should have filters for pretty much every attribute in the Update model. (unless I forgot some, of course)

Last thing to do would be pagination, but I think I'd rather wait to see how we'd use that before doing it, because I'm personally not really familiar with WebHelpers. (or even pagination)

lmacken commented 10 years ago

@ralphbean implemented pagiation in f5ba563d