Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MODINVSTOR-1292: Add item barcode right truncation search index #1116

Merged
merged 4 commits into from
Dec 5, 2024

Conversation

julianladisch
Copy link
Contributor

@julianladisch julianladisch commented Nov 22, 2024

Purpose

Speed up item barcode right truncation searches.

The index for item barcode right truncation will be used by checkin and checkout:
https://github.com/folio-org/ui-checkout/blob/v11.0.0/src/ScanItems.js#L163-L164
https://github.com/folio-org/ui-checkin/blob/v9.2.0/src/Scan.js#L318-L319

The existing btree index doesn’t support right truncation because barcode is Unicode and not "C" locale, for details see
https://www.postgresql.org/docs/current/indexes-opclass.html
https://www.cybertec-postgresql.com/en/indexing-like-postgresql-oracle/

Approach

Add a text_pattern_ops index for item barcode.

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-1292

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

Add text_pattern_ops index for item barcode to speed up right truncation searches.
Copy link

sonarqubecloud bot commented Dec 4, 2024

@julianladisch julianladisch merged commit 746d3ad into master Dec 5, 2024
4 checks passed
@julianladisch julianladisch deleted the MODINVSTOR-1292 branch December 5, 2024 14:02
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.

3 participants