Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add index to scans.status #171

Merged
merged 5 commits into from
Sep 27, 2023
Merged

Add index to scans.status #171

merged 5 commits into from
Sep 27, 2023

Conversation

jonathan-d-zhang
Copy link
Contributor

Adds an index to the scans.status column. This speeds up queries by ~305x.
Testing with:

#!/bin/bash
pgbench -n -f query.sql -T120 -P24 -c5 -j5 \
    postgresql://postgres:postgres@localhost:5432/dragonfly

Existing

number of transactions actually processed: 13585
latency average = 44.165 ms
latency stddev = 0.987 ms
tps = 113.209099 (without initial connection time)

New

number of transactions actually processed: 4140845
latency average = 0.145 ms
latency stddev = 0.025 ms
tps = 34516.420929 (without initial connection time)

Robin5605
Robin5605 previously approved these changes Sep 23, 2023
Copy link
Contributor

@Robin5605 Robin5605 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nothing glaring. lgtm

dependabot bot and others added 3 commits September 26, 2023 20:32
Bumps python from `58ae46e` to `c499230`.

---
updated-dependencies:
- dependency-name: python
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
@shenanigansd shenanigansd enabled auto-merge (squash) September 27, 2023 00:43
@shenanigansd shenanigansd merged commit eb377af into main Sep 27, 2023
7 checks passed
@shenanigansd shenanigansd deleted the scans-index branch September 27, 2023 00:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants