-
Notifications
You must be signed in to change notification settings - Fork 447
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(v1): improve deposit-count-qry (#2984)
* fix(v1): improve deposit-count-qry * fix(v1): improve db.GetTotalAmountDeposited * fix(monitoring): remove obsolete check for validatorStateCountsUpdater * fix(v1): fix db.GetEth2Deposits when searching --------- Co-authored-by: Patrick Pfeiffer <[email protected]>
- Loading branch information
Showing
3 changed files
with
58 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
db/migrations/20241205125552_add_idx_blocks_status_depositscountgt0.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
-- +goose Up | ||
-- +goose StatementBegin | ||
SELECT 'creating idx_blocks_status_depositscountgt0'; | ||
CREATE INDEX CONCURRENTLY IF NOT EXISTS idx_blocks_status_depositscountgt0 ON blocks (status, (depositscount > 0)) where depositscount > 0; | ||
-- +goose StatementEnd | ||
|
||
-- +goose Down | ||
-- +goose StatementBegin | ||
SELECT 'dropping idx_blocks_status_depositscountgt0'; | ||
DROP INDEX CONCURRENTLY IF EXISTS idx_blocks_status_depositscountgt0; | ||
-- +goose StatementEnd |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters