[Bug 10004] New: Delay batch record count updates until the end of the z39.50 search
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10004 Bug ID: 10004 Summary: Delay batch record count updates until the end of the z39.50 search Classification: Unclassified Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: Z39.50 / SRU / OpenSearch Servers Assignee: gmcharlt@gmail.com Reporter: kyle.m.hall@gmail.com CC: m.de.rooy@rijksmuseum.nl Right now when a z39.50 search is run, _update_batch_record_counts is run for each record. If multiple duplicate bibs are in the search, it will be run for each of them. For Koha installations with very large numbers of batches, this can cause significant slowdowns. It would be better to delay this update until the very end so we can update each batch only once. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10004 --- Comment #1 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 17296 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=17296&action=edit Bug 10004 - Delay batch record count updates until the end of the z39.50 search Right now when a z39.50 search is run, _update_batch_record_counts is run for each record. If multiple duplicate bibs are in the search, it will be run for each of them. For Koha installations with very large numbers of batches, this can cause significant slowdowns. It would be better to delay this update until the very end so we can update each batch only once. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10004 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10004 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #17296|0 |1 is obsolete| | --- Comment #2 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 17297 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=17297&action=edit Bug 10004 - Delay batch record count updates until the end of the z39.50 search Right now when a z39.50 search is run, _update_batch_record_counts is run for each record. If multiple duplicate bibs are in the search, it will be run for each of them. For Koha installations with very large numbers of batches, this can cause significant slowdowns. It would be better to delay this update until the very end so we can update each batch only once. In addition, we can fork this process, as it is not neccessary to wait for it before displaying results. Test Plan: 1) Apply patch 2) Perform a z39.50 search -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10004 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #17297|0 |1 is obsolete| | --- Comment #3 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 17298 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=17298&action=edit Bug 10004 - Delay batch record count updates until the end of the z39.50 search Right now when a z39.50 search is run, _update_batch_record_counts is run for each record. If multiple duplicate bibs are in the search, it will be run for each of them. For Koha installations with very large numbers of batches, this can cause significant slowdowns. It would be better to delay this update until the very end so we can update each batch only once. In addition, we can fork this process, as it is not neccessary to wait for it before displaying results. Test Plan: 1) Apply patch 2) Perform a z39.50 search -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10004 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #17298|0 |1 is obsolete| | --- Comment #4 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 17299 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=17299&action=edit Bug 10004 - Delay batch record count updates until the end of the z39.50 search Right now when a z39.50 search is run, _update_batch_record_counts is run for each record. If multiple duplicate bibs are in the search, it will be run for each of them. For Koha installations with very large numbers of batches, this can cause significant slowdowns. It would be better to delay this update until the very end so we can update each batch only once. In addition, we can fork this process, as it is not neccessary to wait for it before displaying results. Test Plan: 1) Apply patch 2) Perform a z39.50 search -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10004 Kyle M Hall <kyle.m.hall@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|gmcharlt@gmail.com |kyle.m.hall@gmail.com -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10004 --- Comment #5 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 17307 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=17307&action=edit Bug 10004 - Delay batch record count updates until the end of the z39.50 search [3.8.x] [3.10.x] Right now when a z39.50 search is run, _update_batch_record_counts is run for each record. If multiple duplicate bibs are in the search, it will be run for each of them. For Koha installations with very large numbers of batches, this can cause significant slowdowns. It would be better to delay this update until the very end so we can update each batch only once. In addition, we can fork this process, as it is not neccessary to wait for it before displaying results. Test Plan: 1) Apply patch 2) Perform a z39.50 search -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10004 Kyle M Hall <kyle.m.hall@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #17307|0 |1 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10004 Kyle M Hall <kyle.m.hall@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Severity|enhancement |minor -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10004 --- Comment #6 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Hm. I am not sure if we really should start forking in a cgi script. (Not saying that your solution would not work :) But going one step back: Can we not just get rid of these *silly* record counts for Z3950 searches? These counts may be of some interest for staged marc files and so on. But what are we doing with these numbers for Z3950 search? I cannot recall seeing this number anywhere in Koha. So, why not stop calculating instead of doing it in a second process? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10004 Chris Cormack <chris@bigballofwax.co.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |In Discussion CC| |chris@bigballofwax.co.nz -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10004 --- Comment #7 from Kyle M Hall <kyle.m.hall@gmail.com> --- I believe these numbers are updated because the records found via the z39.50 search go into the import_records table. Each time a record is added to that batch, the count is recalculated and stored in the import_batches table. (In reply to comment #6)
Hm. I am not sure if we really should start forking in a cgi script. (Not saying that your solution would not work :)
But going one step back: Can we not just get rid of these *silly* record counts for Z3950 searches? These counts may be of some interest for staged marc files and so on. But what are we doing with these numbers for Z3950 search? I cannot recall seeing this number anywhere in Koha.
So, why not stop calculating instead of doing it in a second process?
-- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10004 Kyle M Hall <kyle.m.hall@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|In Discussion |Needs Signoff --- Comment #8 from Kyle M Hall <kyle.m.hall@gmail.com> --- I should also not a number of our cgi scripts fork children for ajax purposes, so this is not without precedent. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10004 --- Comment #9 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- (In reply to comment #7)
I believe these numbers are updated because the records found via the z39.50 search go into the import_records table. Each time a record is added to that batch, the count is recalculated and stored in the import_batches table.
You describe what happens but why should we do something that we do not use later? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10004 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |RESOLVED Resolution|--- |FIXED --- Comment #10 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- Bug 10462 has resolved the issue of the unused batch record counts for Z3950 search. -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org