Summary: | Deleted items are not removed from index | ||
---|---|---|---|
Product: | Koha | Reporter: | Björn Nylén <bjorn.nylen> |
Component: | Cataloging | Assignee: | Björn Nylén <bjorn.nylen> |
Status: | CLOSED FIXED | QA Contact: | Nick Clemens (kidclamp) <nick> |
Severity: | major | ||
Priority: | P5 - low | CC: | aleisha, lucas, m.de.rooy, nick, severine.queune, stefan.berndtsson |
Version: | Main | ||
Hardware: | All | ||
OS: | All | ||
Change sponsored?: | --- | Patch complexity: | Small patch |
Documentation contact: | Documentation submission: | ||
Text to go in the release notes: | Version(s) released in: |
20.11.00, 20.05.06
|
|
Circulation function: | |||
Bug Depends on: | 23463 | ||
Bug Blocks: | |||
Attachments: |
Index after item deletion
Bug 26750: Deleted items not indexed Bug 26750: Deleted items not indexed |
Description
Björn Nylén
2020-10-20 12:12:34 UTC
Created attachment 112030 [details] [review] Index after item deletion After deleting an item it is still searchable in the index. Similar to bug 26507 where record is reindexed before the database is changed. To test: 1. Delete an item 2. Search the barcode in the main search box. You'll find the original record but wiht hte deleted item missing. 3. Apply patch. 4. Repeat steps 1-2 (with another item). No record should be found. Can't reproduce using ElasticSearch, is that a specific Zebra problem ? No we're using ES as well. The issue is in the Koha::Itemm->delete call where indexing takes place before deletion. We're on 20.05.03 and the problem is there. The indexing call is changed in master but the order of events is the same. Created attachment 112401 [details] [review] Bug 26750: Deleted items not indexed After deleting an item it is still searchable in the index. Similar to bug 26507 where record is reindexed before the database is changed. To test: 1. Delete an item 2. Search the barcode in the main search box. You'll find the original record but wiht hte deleted item missing. 3. Apply patch. 4. Repeat steps 1-2 (with another item). No record should be found. Note to test you have to have the indexer running, not the cron job, and it needs to be running fast so that the index is updated before the delete takes place Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Created attachment 112435 [details] [review] Bug 26750: Deleted items not indexed After deleting an item it is still searchable in the index. Similar to bug 26507 where record is reindexed before the database is changed. To test: 1. Delete an item 2. Search the barcode in the main search box. You'll find the original record but wiht hte deleted item missing. 3. Apply patch. 4. Repeat steps 1-2 (with another item). No record should be found. Note to test you have to have the indexer running, not the cron job, and it needs to be running fast so that the index is updated before the delete takes place Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Logging and item hooks still get necessary info after this and indexing works, nice one! Pushed to master for 20.11, thanks to everybody involved! backported to 20.05.x for 20.05.06 doesn't apply cleanly for 19.11.x, please rebase (In reply to Aleisha Amohia from comment #10) > doesn't apply cleanly for 19.11.x, please rebase This bug was introduced by Bug 23463 so shouldn't exist in 19.11 (In reply to Björn Nylén from comment #11) > (In reply to Aleisha Amohia from comment #10) > > doesn't apply cleanly for 19.11.x, please rebase > > This bug was introduced by Bug 23463 so shouldn't exist in 19.11 Thanks, I'll add this to the bug report. |