JobCountByState query performance
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 35/100
- Issue type
- Bug
- Clarity
- Needs clarification
- Activity status
- Stale
- Tech stack
- typescript
- Domain
- databases
Research direction
Start at api_handler.go around the linked JobCountByState query and reproduce its performance with a large jobs table. Inspect the query plan and existing indexes, then verify that the selected change makes the API request complete without timing out on a comparable dataset.
Written by the indexing model from the issue text.
Description
Hey,
I'm really enjoying river so far, so thank you for that!
I was playing around with River UI, but on a table with just over 5 million jobs the queries become so slow that the api requests are timing out and I'm just getting a white screen (specifically the JobCountByState query). Haven't looked into it too much, so not sure if it's just missing an index somewhere.
This is happening both on my local M2 MacbookPro and on a small AlloyDB instance.
EDIT:
For some numbers, that query took 9s to complete on AlloyDB (which admittedly is under heavy use at the moment). The same query took just over 3s on my otherwise idle Macbook.
- Dominant language
- TypeScript
- Stars
- 236
- Forks
- 39
- Avg merge
- 3h 40m
- Merged PRs (30d)
- 23
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from riverqueue/riverui
-
Difficulty 2/5 1-3 hours Newbie friendliness 66/100
riverqueue/riverui#448 · 4 comments ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
riverqueue/riverui#102 · 2 comments ·
-
Difficulty 5/5 Over a week Newbie friendliness 35/100
riverqueue/riverui#590 · 1 comment ·
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
riverqueue/riverui#479 · 3 comments · 1 reaction ·
-
Difficulty 3/5 1-2 days Newbie friendliness 35/100
riverqueue/riverui#441 · 6 comments ·
All issues in riverqueue/riverui
Similar issues
-
clawsweeper:linked-pr-open clawsweeper:no-new-fix-pr clawsweeper:source-repro impact:message-loss issue-rating: 🦞 diamond lobster maturity:stable P2
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Eynzof/Hermes-CN-Desktop#616 ·
-
ZCode 3.14.3 に対応する Open
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
supermomonga/zcode-acp#24 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
growthbook/growthbook#7100 ·
-
triage
Difficulty 1/5 1-3 hours Newbie friendliness 88/100