[Koha-bugs] [Bug 23377] bulkmarcimport.pl disables syspref caching

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Fri Jan 10 11:53:39 CET 2020


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=23377

Marcel de Rooy <m.de.rooy at rijksmuseum.nl> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #97143|0                           |1
        is obsolete|                            |

--- Comment #4 from Marcel de Rooy <m.de.rooy at rijksmuseum.nl> ---
Created attachment 97183
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=97183&action=edit
Bug 23377: use ENV syspref override instead of complete disable

In an attempt to save time, bulkmarcimport temporarily sets CataloguingLog
and AuthoritiesLog to 0.  It does this by disabling syspref caching and saving
the changes to the database (then replacing the original values at completion).

Unfortunately, this disables other key sysprefs from being cached, and results
in
a 50% increase in processing time for the script.

This patch instead utilizes the ENV variable override feature of sysprefs,
which
preempts the cache in C4::Context->preference().

To test:
1. Perform a bulkmarcimport with a reasonable number of biblios (~1000 will do)
2. Note the time taken to complete
3. Apply patch
4. Revert the biblio load performed
5. Perform another bulkmarcimport with the same biblios and commandline options
6. Note the time taken to complete
7. Compare times.  The time from step 6 should be about 33% less than the time
from step 2
8. Check Cataloguing and Authorities Logs to verify imported records were not
logged
9. Profit!

Signed-off-by: Michal Denar <black23 at gmail.com>

Signed-off-by: Marcel de Rooy <m.de.rooy at rijksmuseum.nl>

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list