]> git.ipfire.org Git - thirdparty/patchwork.git/commit
Be sensible computing project patch counts
authorStewart Smith <stewart@linux.ibm.com>
Fri, 10 Aug 2018 08:01:05 +0000 (18:01 +1000)
committerStephen Finucane <stephen@that.guru>
Mon, 10 Sep 2018 20:24:24 +0000 (14:24 -0600)
commitcfcf2f2a80ac0709f1a5fd9aa212c8403daa5a18
treeff5f92db746c00771b6588246bc16bb0ee602edc
parente5c641fc47dae131cccefd49d7818eb249bbb7fb
Be sensible computing project patch counts

Django actively fights constructing a query that isn't insane.

So, let's go and just execute a raw one. This is all very standard
SQL so should execute everywhere without a problem.

With the dataset of patchwork.ozlabs.org, looking at the /project/
page for qemu-devel would take 13 queries and 1500ms,
with this patch it's down to 11 queries in ~250ms.
For the dataset of the netdev list, it's down to 440ms from 1500ms.

Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
[stephenfin: Handle projects that have no archived patches and those
 with all patches archived]
Signed-off-by: Stephen Finucane <stephen@that.guru>
patchwork/views/project.py