From a86dfb23dda03b69b3e223e48fd1b6fc5c0b24f5 Mon Sep 17 00:00:00 2001 From: Zach Date: Fri, 12 Jun 2026 08:28:10 -0400 Subject: [PATCH] perf(db): add missing `book_file` indices for ingestion lookups (#1729) --- .../db/migration/V142__Add_book_file_ingest_indexes.sql | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 backend/src/main/resources/db/migration/V142__Add_book_file_ingest_indexes.sql diff --git a/backend/src/main/resources/db/migration/V142__Add_book_file_ingest_indexes.sql b/backend/src/main/resources/db/migration/V142__Add_book_file_ingest_indexes.sql new file mode 100644 index 000000000..b7d66f140 --- /dev/null +++ b/backend/src/main/resources/db/migration/V142__Add_book_file_ingest_indexes.sql @@ -0,0 +1,2 @@ +CREATE INDEX IF NOT EXISTS idx_book_file_current_hash ON book_file (current_hash); +CREATE INDEX IF NOT EXISTS idx_book_file_path ON book_file (file_sub_path(255), file_name(255));