storj/satellite/satellitedb/dbx
Ethan 9a29ec5b3e Add index to graceful_exit_transfer_queue table
This fixes a slow query that was taking up to 4 seconds in production

SELECT node_id, path, piece_num, root_piece_id, durability_ratio, queued_at, requested_at, last_failed_at, last_failed_code, failed_count, finished_at, order_limit_send_count
	FROM graceful_exit_transfer_queue
	WHERE node_id = '[redacted]'
	AND finished_at is NULL
	AND last_failed_at is NULL
	ORDER BY durability_ratio asc, queued_at asc LIMIT 300 OFFSET 0;

Change-Id: Ib89743ca35f1d8d0a1456b20fa08c683ebdc1549
2020-10-26 14:47:48 +00:00
..
templates satellite/satellitedb/dbx: monitor the database calls 2019-12-18 21:57:36 +00:00
gen.go all: add missing dots 2020-08-11 17:50:01 +03:00
gen.sh all: use jackc/pgx in place of lib/pq 2020-07-13 15:54:41 +00:00
satellitedb.dbx Add index to graceful_exit_transfer_queue table 2020-10-26 14:47:48 +00:00
satellitedb.dbx.go Add index to graceful_exit_transfer_queue table 2020-10-26 14:47:48 +00:00
satellitedb.dbx.pgx.sql Add index to graceful_exit_transfer_queue table 2020-10-26 14:47:48 +00:00
satellitedb.dbx.pgxcockroach.sql Add index to graceful_exit_transfer_queue table 2020-10-26 14:47:48 +00:00