]> git.koha-community.org Git - koha.git/commit
Bug 22258: Elasticsearch: Add array as an alternative MARC format
authorEre Maijala <ere.maijala@helsinki.fi>
Fri, 15 Feb 2019 11:32:03 +0000 (13:32 +0200)
committerMartin Renvoize <martin.renvoize@ptfs-europe.com>
Fri, 6 Sep 2019 11:53:46 +0000 (12:53 +0100)
commit4f42ea51d74325af6282420ef11ba539c784ffd7
tree09c32753843be3a7de67258425f9c3229d97cec8
parent18d8d3b38b367ee0ea10169a0433e4a273252f15
Bug 22258: Elasticsearch: Add array as an alternative MARC format

Adds preference ElasticsearchMARCFormat that controls whether MARC records are stored as ISO2709/MARCXML or array. Array is searchable by field and also indexes all subfields in the _all field for searching.

Test plan:
1. Test that searching and indexing works with the patch without any changes.
2. Switch to array format and index some records.
3. Check e.g. the 008 field of a record and verify that the record can be found with the contents enclosed in quotes.
4. Check that it's possible to search for a specific field/subfield. Search query: marc_data_array.fields.655.subfields.a:Diaries
5. Check that tests still pass, especially t/Koha/SearchEngine/Elasticsearch.t

Signed-off-by: Michal Denar <black23@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Koha/SearchEngine/Elasticsearch.pm
Koha/SearchEngine/Elasticsearch/Search.pm
admin/searchengine/elasticsearch/field_config.yaml
installer/data/mysql/atomicupdate/bug_22258.perl [new file with mode: 0644]
installer/data/mysql/sysprefs.sql
koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/admin.pref
t/Koha/SearchEngine/Elasticsearch.t