pagination does not speed up list queries
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Shared File Systems Service (Manila) |
Fix Released
|
Medium
|
Carlos Eduardo |
Bug Description
Hi,
let's say I have 500 shares in my project, listing this with all export locations, metadata etc. can take a while (up to 1 min in our production env, subject to missing indices due to postgresql).
So I decide to use pagination to speed up the listing, but this helps nothing at all:
e.g. GET /shares/
This is common to all list operations.
Solution idea: get the limit down to the db query. (The way cinder still does it today was thrown away in https:/
tags: | added: db |
Changed in manila: | |
status: | New → Confirmed |
summary: |
- pagination limit not enforced on db + pagination does not speed up list queries |
Changed in manila: | |
importance: | Undecided → Low |
Changed in manila: | |
assignee: | nobody → Carlos Eduardo (silvacarlose) |
status: | Confirmed → In Progress |
Changed in manila: | |
assignee: | Carlos Eduardo (silvacarlose) → Tom Barron (tpb) |
Changed in manila: | |
assignee: | Tom Barron (tpb) → Carlos Eduardo (silvacarlose) |
Changed in manila: | |
milestone: | none → train-rc1 |
tags: | added: queens-backport-potential rocky-backport-potential stein-backport-potential train-rc1-potential |
Thanks for this bug report Maurice.
I haven't done any perf tests against the API, do you think the solution here [1] will be better than what we're doing today? If it does, we might need a volunteer to fix our current "list" APIs to take advantage of the pagination at the DB layer than the API layer. Would you be interested in committing this fix?
[1] https:/ /review. openstack. org/#/c/ 572283/ 22/manila/ db/sqlalchemy/ api.py@ 2146