Skip to content

MODINVSTOR-1277: Delete 6 unused instance database indexes#1101

Merged
psmagin merged 7 commits intomasterfrom
MODINVSTOR-1277
Mar 3, 2025
Merged

MODINVSTOR-1277: Delete 6 unused instance database indexes#1101
psmagin merged 7 commits intomasterfrom
MODINVSTOR-1277

Conversation

@julianladisch
Copy link
Copy Markdown
Contributor

Purpose

Delete the 6 biggest database indexes that are never used.

  • instance_identifiers_idx_gin
  • instance_identifiers_idx_ft
  • instance_title_idx
  • instance_contributors_idx
  • instance_indextitle_idx
  • instance_publication_idx

Approach

  • Delete 6 unused instance database indexes by marking them for deletion in schema.json
  • This autoamtically drops CQL array support for identifiers, therefore delete identifiers array unit tests
  • Delete PgUtil.getWithOptimizedSql code because the title index has been deleted
  • Delete populateRmbInternalIndex.sql because it runs for mod-inventory-storage <= 19.1.0

Changes Checklist

  • API Changes: Document any API paths, methods, request or response bodies changed, added, or removed.
  • Database Schema Changes: Indicate any database schema changes and their impact. Confirm that migration scripts were created.
  • Interface Version Changes: Indicate any changes to interface versions.
  • Interface Dependencies: Document added or removed dependencies.
  • Permissions: Document any changes to permissions.
  • Logging: Confirm that logging is appropriately handled.
  • Unit Testing: Confirm that changed classes were covered by unit tests.
  • Integration Testing: Confirm that changed logic was covered by integration tests.
  • Manual Testing: Confirm that changes were tested on local or dev environment.
  • NEWS: Confirm that the NEWS file is updated with relevant information about the changes made in this pull request.

Related Issues

https://folio-org.atlassian.net/browse/MODINVSTOR-1277

…array support for identifiers

https://folio-org.atlassian.net/browse/MODINVSTOR-1277

* Delete 6 unused instance database indexes:
  * instance_identifiers_idx_gin
  * instance_identifiers_idx_ft
  * instance_title_idx
  * instance_contributors_idx
  * instance_indextitle_idx
  * instance_publication_idx
* Drop CQL array support for identifiers, delete identifiers array unit tests
* Delete PgUtil.getWithOptimizedSql because the title index has been deleted
* Delete populateRmbInternalIndex.sql because it runs for mod-inventory-storage <= 19.1.0
@sonarqubecloud
Copy link
Copy Markdown

Copy link
Copy Markdown
Collaborator

@psmagin psmagin left a comment

Choose a reason for hiding this comment

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

Please update NEWS by moving it's updates into not-released block.

@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud bot commented Jan 3, 2025

Copy link
Copy Markdown
Contributor

@mweaver-ebsco mweaver-ebsco left a comment

Choose a reason for hiding this comment

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

Please keep the 2 indexes that are actively being used by mod-fqm-manager, as mentioned in my previous comment (adding a separate comment because github won't let me hit "request changes" without a new comment)

psmagin added 2 commits March 3, 2025 11:01
# Conflicts:
#	NEWS.md
#	src/main/java/org/folio/rest/impl/InstanceStorageApi.java
@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud bot commented Mar 3, 2025

@psmagin psmagin dismissed mweaver-ebsco’s stale review March 3, 2025 09:40

Removing title and indexTitle indexes was reverted

@psmagin psmagin merged commit 3eb814e into master Mar 3, 2025
6 checks passed
@psmagin psmagin deleted the MODINVSTOR-1277 branch March 3, 2025 09:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants