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 requestkey indexes on events and transactions #98

Merged
merged 1 commit into from
Nov 30, 2022

Conversation

enobayram
Copy link
Contributor

As identified by @blazesal in #79, our /txs/tx endpoint requires a requestkey index on the events and transactions tables, otherwise each request results in a table scan.

I've just tried creating these indexes manually and checking their sizes; As of now, the requestkey index on the transactions table takes up 603MB of space while the one on events takes up 879MB. For comparison, these total space occupied by these two tables is ~46GB.

As identified by @blazesal in
#79, our `/txs/tx`
endpoint requires a requestkey index on the events and transactions
tables, otherwise each request results in a table scan.

I've just tried creating these indexes manually and checking their
sizes; As of now, the requestkey index on the transactions table takes
up 603MB of space while the one on events takes up 879MB. For
comparison, these total space occupied by these two tables is ~46GB.
@enobayram enobayram self-assigned this Nov 29, 2022
Copy link
Contributor

@emmanueldenloye emmanueldenloye left a comment

Choose a reason for hiding this comment

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

LGTM

@enobayram enobayram merged commit e20781d into master Nov 30, 2022
@enobayram enobayram deleted the enis/add_request_key_indexes branch November 30, 2022 13:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants