Skip to content

Commit

Permalink
feat(eventindexer): add indexes to querying optimizations (#13951)
Browse files Browse the repository at this point in the history
  • Loading branch information
cyberhorsey authored Jun 11, 2023
1 parent 8054497 commit 66649bd
Show file tree
Hide file tree
Showing 4 changed files with 36 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
-- +goose Up
-- +goose StatementBegin
ALTER TABLE `events` ADD INDEX `address_index` (`address`);

-- +goose StatementEnd
-- +goose Down
-- +goose StatementBegin
DROP INDEX address_index on events;
-- +goose StatementEnd
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
-- +goose Up
-- +goose StatementBegin
ALTER TABLE `events` ADD INDEX `event_index` (`event`);

-- +goose StatementEnd
-- +goose Down
-- +goose StatementBegin
DROP INDEX event_index on events;
-- +goose StatementEnd
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
-- +goose Up
-- +goose StatementBegin
ALTER TABLE `events` ADD INDEX `block_id_index` (`block_id`);

-- +goose StatementEnd
-- +goose Down
-- +goose StatementBegin
DROP INDEX block_id_index on events;
-- +goose StatementEnd
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
-- +goose Up
-- +goose StatementBegin
ALTER TABLE `events` ADD INDEX `address_and_event_index` (`address`, `event`);

-- +goose StatementEnd
-- +goose Down
-- +goose StatementBegin
DROP INDEX address_and_event_index on events;
-- +goose StatementEnd

0 comments on commit 66649bd

Please sign in to comment.