https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=32920 Bug ID: 32920 Summary: ES indexer should gracefully handle a bad bib record when reindexing after a batch modification Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: normal Priority: P5 - low Component: Searching - Elasticsearch Assignee: koha-bugs@lists.koha-community.org Reporter: emily.lamancusa@montgomerycountymd.gov When Elasticsearch reindexes after a batch modification, if one of the modified biblio records contains invalid data, the "Update Elasticsearch Index" job will fail without updating the search indexing for any of the modified records. When reindexing multiple records at once, an error with one record should not prevent the others from being reindexed correctly. To reproduce: 1. Set SearchEngine system preference to 'Elasticsearch' 2. Find or produce a biblio record that contains invalid data (in KTD's sample data, biblionumber 369 works for this) 3. Confirm that the biblio record detail page in the staff interface displays an invalid data error 4. Generate a barcode file that includes items attached to this biblio as well as other items 5. Perform a batch item modification 6. Open the job list. Note "Finished" status for batch item mod job, and "Failed" status for Update Elasticsearch index job 7. Find the modified records via catalog search. Note that none of the modified items display the updated information in the catalog search. I reproduced this error on KTD, by doing a batch edit on all items with publication date 198_ In case it's useful, error message from the failed job: ^ at /kohadevbox/koha/Koha/Biblio/Metadata.pm line 114. DEBUG - Update of elastic index failed with: Invalid data, cannot decode metadata object (biblio_metadata.id=368, biblionumber=369, format=marcxml, schema=MARC21, decoding_error=':8: parser error : PCDATA invalid Char value 31 <controlfield tag="001">00aD000015937</controlfield> ^ :9: parser error : PCDATA invalid Char value 31 <controlfield tag="004">00satmrnu0</controlfield> ^ :9: parser error : PCDATA invalid Char value 31 <controlfield tag="004">00satmrnu0</controlfield> ^ :9: parser error : PCDATA invalid Char value 31 <controlfield tag="004">00satmrnu0</controlfield> ^ :9: parser error : PCDATA invalid Char value 31 <controlfield tag="004">00satmrnu0</controlfield> ^ :10: parser error : PCDATA invalid Char value 31 <controlfield tag="008">00ar19881981bdkldan</controlfield> ^ :10: parser error : PCDATA invalid Char value 31 <controlfield tag="008">00ar19881981bdkldan</controlfield> ^ :10: parser error : PCDATA invalid Char value 31 <controlfield tag="008">00ar19881981bdkldan</controlfield> ^') -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.