LP#
1526858: speed up queries for shelf-expired holds during checkin
This patch adds indexes on action.hold_request and tweaks
the definition of the alhr IDL view to more efficiently
identify holds that can be canceled if the "Clear Holds Shelf"
checkin modifier is in use. This can prevent a problem
where such checkins can time out in very large databases.
The tweaks were created by Jason Etheridge and have been in
production at a large consortium for some time.
To test
-------
[1] With a suitably large database, set up an item that
is on the holds shelf but has passed its shelf-expiration
time, then check it in using the "Clear Holds Shelf" modifier.
[2] The checkin may fail with a "network failure" message due
the query on the alhr timing out.
[3] Apply the patch and repeat step 1. This time, the checkin
should succeed.
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Jeanette Lundgren <jlundgren@cwmars.org>
Signed-off-by: Kathy Lussier <klussier@masslnc.org>