Summary: | Sync marc21-retrieval-info-auth-dom.xml with retrieval-info-auth-dom.xml | ||
---|---|---|---|
Product: | Koha | Reporter: | David Cook <dcook> |
Component: | Searching - Zebra | Assignee: | David Cook <dcook> |
Status: | Pushed to oldstable --- | QA Contact: | |
Severity: | minor | ||
Priority: | P5 - low | CC: | david, eden.bacani, fridolin.somers, lucas, vfaafia29 |
Version: | Main | Keywords: | Academy |
Hardware: | All | ||
OS: | All | ||
Change sponsored?: | --- | Patch complexity: | --- |
Documentation contact: | Documentation submission: | ||
Text to go in the release notes: |
This fixes the syntax in marc21-retrieval-info-auth-dom.xml, so that one can use the Zebra special retrieval elements documented at https://software.indexdata.com/zebra/doc/special-retrieval.html
These are very useful when troubleshooting issues with authority records in Zebra.
|
Version(s) released in: |
24.05.00,23.11.06,23.05.12
|
Circulation function: | |||
Attachments: |
Bug 27198: Fix syntax in marc21-retrieval-info-auth-dom.xml
Bug 27198: Fix syntax in marc21-retrieval-info-auth-dom.xml Bug 27198: Fix syntax in marc21-retrieval-info-auth-dom.xml Bug 27198: Fix syntax in marc21-retrieval-info-auth-dom.xml |
Description
David Cook
2020-12-11 04:23:37 UTC
Before patch: root@kohadevbox:koha(bug27198)$ yaz-client unix:/var/run/koha/kohadev/authoritysocket Connecting...OK. Sent initrequest. Connection accepted by v3 target. ID : 81 Name : Zebra Information Server/GFS/YAZ Version: 4.2.30 98864b44c654645bc16b2c54f822dc2e45a93031 Options: search present delSet triggerResourceCtrl scan sort extendedServices namedResultSets Elapsed: 0.000754 Z> base authorities Z> format xml Z> elements zebra::snippet Z> find e Sent searchRequest. Received SearchResponse. Search was a success. Number of hits: 21, setno 1 SearchResult-1: term=e cnt=21 records returned: 0 Elapsed: 0.002167 Z> show 1 Sent presentRequest (1+1). Diagnostic message(s) from database: [25] Specified element set name not valid for specified database -- v2 addinfo 'zebra::snippet' nextResultSetPosition = 2 Elapsed: 0.000218 Z> exit See you later, alligator. After patch: root@kohadevbox:koha(bug27198)$ yaz-client unix:/var/run/koha/kohadev/authoritysocket Connecting...OK. Sent initrequest. Connection accepted by v3 target. ID : 81 Name : Zebra Information Server/GFS/YAZ Version: 4.2.30 98864b44c654645bc16b2c54f822dc2e45a93031 Options: search present delSet triggerResourceCtrl scan sort extendedServices namedResultSets Elapsed: 0.000840 Z> base authorities Z> format xml Z> elements zebra::snippet Z> find e Sent searchRequest. Received SearchResponse. Search was a success. Number of hits: 21, setno 1 SearchResult-1: term=e cnt=21 records returned: 0 Elapsed: 0.002212 Z> show 1 Sent presentRequest (1+1). Records: 1 Record type: XML <record xmlns="http://www.indexdata.com/zebra/"> <snippet name="Any" type="w">Gontarski, S. <s>E</s></snippet> </record>nextResultSetPosition = 2 Elapsed: 0.013929 Created attachment 114319 [details] [review] Bug 27198: Fix syntax in marc21-retrieval-info-auth-dom.xml This patch fixes the syntax in marc21-retrieval-info-auth-dom.xml, so that one can use the Zebra special retrieval elements documented at https://software.indexdata.com/zebra/doc/special-retrieval.html These are very useful when troubleshooting issues with authority records in Zebra. Listing this one as Academy as it's pretty straight-forward. Happy to help people with this one too. Can you please provide a test plan? (In reply to Victoria Faafia from comment #4) > Can you please provide a test plan? Ooops I forgot to label it but you should be able to use Comment 1 (https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27198#c1) as a test plan. Followed the test plan but an error kept recurring even after applying patch. Is there a step missing such as rebuilding zebra etc? (In reply to Eden from comment #6) > Followed the test plan but an error kept recurring even after applying > patch. Is there a step missing such as rebuilding zebra etc? Ah, yes. My mistake! Not rebuilding Zebra, but restarting Zebra for sure. - koha-zebra --stop kohadev - pkill zebrasrv - koha-zebra --start kohadev That should do the trick. The pkill zebrasrv is there because koha-zebra --stop kohadev won't work if the zebrasrv process has forked child processes. Hi David. I had a go at testing. Test plan: 1. yaz-client unix:/var/run/koha/kohadev/authoritysocket 2. Enter these commands (see comment #1): . base authorities . format xml . elements zebra::snippet . find e . show 1 3. Result = diagnostic message: Diagnostic message(s) from database: [25] Specified element set name not valid for specified database -- v2 addinfo 'zebra::snippet' 4. Apply the patch 5. Stop and restart zebra (no need to rebuild the Zebra index): . koha-zebra --stop kohadev . pkill zebrasrv . koha-zebra --start kohadev 6. Repeat commands in step 2. 7. Result from show 1 = XML output: Sent presentRequest (1+1). Records: 1 Record type: XML <record xmlns="http://www.indexdata.com/zebra/"> <snippet name="Any" type="w">Gontarski, S. <s>E</s></snippet> </record>nextResultSetPosition = 2 Elapsed: 0.013929 I still get the results as per step 3. The only thing I noticed is that the version information is different when you connect - 2.0.59 instead of 4.2.30: root@kohadevbox:koha(bz27198)$ yaz-client unix:/var/run/koha/kohadev/authoritysocket Connecting...OK. Sent initrequest. Connection accepted by v3 target. ID : 81 Name : Zebra Information Server/GFS/YAZ Version: 2.0.59/5.27.1 872b6f92a024bb53bc1c11dfeccd47f065f98238 Options: search present delSet triggerResourceCtrl scan sort extendedServices namedResultSets Elapsed: 0.002171 Z> I am using koha-testing-docker. David Hmm interesting. Happy for you to mark this as Failed QA. I'm probably not going to review it any time soon, to be honest. Oh man... looking back on this and it's so obvious what I was missing in the test plan. I made the assumption that the tester had copied the file. After applying the patch, you'll need to do the following: cp debian/templates/marc21-retrieval-info-auth-dom.xml /etc/koha/marc21-retrieval-info-auth-dom.xml Created attachment 163664 [details] [review] Bug 27198: Fix syntax in marc21-retrieval-info-auth-dom.xml This patch fixes the syntax in marc21-retrieval-info-auth-dom.xml, so that one can use the Zebra special retrieval elements documented at https://software.indexdata.com/zebra/doc/special-retrieval.html These are very useful when troubleshooting issues with authority records in Zebra. Signed-off-by: David Nind <david@davidnind.com> Created attachment 163665 [details] [review] Bug 27198: Fix syntax in marc21-retrieval-info-auth-dom.xml This patch fixes the syntax in marc21-retrieval-info-auth-dom.xml, so that one can use the Zebra special retrieval elements documented at https://software.indexdata.com/zebra/doc/special-retrieval.html These are very useful when troubleshooting issues with authority records in Zebra. Test plan (using KTD): 1. yaz-client unix:/var/run/koha/kohadev/authoritysocket 2. Enter these commands: . base authorities . format xml . elements zebra::snippet . find e . show 1 3. Result = diagnostic message: Diagnostic message(s) from database: [25] Specified element set name not valid for specified database -- v2 addinfo 'zebra::snippet' 4. Apply the patch 5. Copy updated file: sudo cp debian/templates/marc21-retrieval-info-auth-dom.xml /etc/koha/marc21-retrieval-info-auth-dom.xml 6. Stop and restart zebra (no need to rebuild the Zebra index): . sudo koha-zebra --stop kohadev . sudo pkill zebrasrv . sudo koha-zebra --start kohadev 7. Repeat commands in step 2. 8. Result from show 1 = XML output: Sent presentRequest (1+1). Records: 1 Record type: XML <record xmlns="http://www.indexdata.com/zebra/"> <snippet name="Any" type="w">Gontarski, S. <s>E</s></snippet> </record>nextResultSetPosition = 2 Elapsed: 0.013929 Signed-off-by: David Nind <david@davidnind.com> I have: 1. Amended the patch to include the test plan 2. Changed the assignee Created attachment 164177 [details] [review] Bug 27198: Fix syntax in marc21-retrieval-info-auth-dom.xml This patch fixes the syntax in marc21-retrieval-info-auth-dom.xml, so that one can use the Zebra special retrieval elements documented at https://software.indexdata.com/zebra/doc/special-retrieval.html These are very useful when troubleshooting issues with authority records in Zebra. Test plan (using KTD): 1. yaz-client unix:/var/run/koha/kohadev/authoritysocket 2. Enter these commands: . base authorities . format xml . elements zebra::snippet . find e . show 1 3. Result = diagnostic message: Diagnostic message(s) from database: [25] Specified element set name not valid for specified database -- v2 addinfo 'zebra::snippet' 4. Apply the patch 5. Copy updated file: sudo cp debian/templates/marc21-retrieval-info-auth-dom.xml /etc/koha/marc21-retrieval-info-auth-dom.xml 6. Stop and restart zebra (no need to rebuild the Zebra index): . sudo koha-zebra --stop kohadev . sudo pkill zebrasrv . sudo koha-zebra --start kohadev 7. Repeat commands in step 2. 8. Result from show 1 = XML output: Sent presentRequest (1+1). Records: 1 Record type: XML <record xmlns="http://www.indexdata.com/zebra/"> <snippet name="Any" type="w">Gontarski, S. <s>E</s></snippet> </record>nextResultSetPosition = 2 Elapsed: 0.013929 Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Pushed for 24.05! Well done everyone, thank you! Pushed to 23.11.x for 23.11.06 Backported to 23.05.x for upcoming 23.05.12 |