[Koha-bugs] [Bug 11998] Syspref caching issues

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Fri Mar 4 14:36:45 CET 2016


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

--- Comment #107 from Jonathan Druart <jonathan.druart at bugs.koha-community.org> ---
(In reply to Jacek Ablewicz from comment #104)
> - bunch of t/* tests (quite o lot of them) is still using ->set_preference()
> insted of mock_preference() - they don't commit changes to the database, but
> running them may now result in syspref "cache poisoning", affecting
> behaviour of the other processes

Yes, that is addressed in the last 2 patches.

> - remaining code chunks which are dealing with systempreferences table
> directly (installer, updatedatabase.pl, some tests and admin/maintenance
> scripts); updatedatabase.pl seems to be OK (at least at the 1st glance), not
> sure about installer - it does call clear_syspref_cache() 1+ time, but not
> necessarily everywhere where it should do it / not at the each and every
> step (?)

Yes, we should replace them, and avoid to update/insert sysprefs during the
update DB process.

> - up to now, when a given script retrieved some preference once, it was
> guaranted that all subsequent ->preference() calls during the script run
> will return the same value; now it will always use the current value instead
> - I guess sometimes that will be a good thing, and sometimes not so much -
> but probably not very important in practical circumstances

Theoretically it could be an issue but, as you said, I don't think it could be
a problem in practice.

> Also there will be some (hopefully very) little performace hit due to
> caching system overheads (and 10 sec deafult expire in case of Cache::Memory
> - but it will affect only the long-running scripts) - how little, it remains
> to be seen ;)

In conjunction with other patches (depending on this bug report), I am
expecting a gain.

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


More information about the Koha-bugs mailing list