Bug 11842 - fix framework caching with memcache/plack
authorRobin Sheat <robin@catalyst.net.nz>
Thu, 10 Apr 2014 05:11:50 +0000 (17:11 +1200)
committerTomas Cohen Arazi <tomascohen@gmail.com>
Tue, 19 Aug 2014 15:53:44 +0000 (12:53 -0300)
commit71ba269136c61e57e8388f91f2562d062004d7fd
tree1c3b0be7b0d5c8ad2ead40cd5b81af6469fde0a0
parent4107444c03ba54078cf6b167b70cfff31d13b0f0
Bug 11842 - fix framework caching with memcache/plack

This changes the existing framework caching, which was using memoisation
if memcached was available, and memory in all cases, to use the
Koha::Cache system. This uses memcache if possible, and in-memory
otherwise. However it also clears the cache when the framework updates,
making sure that the changed version will be picked up.

Note that the in-memory cache clears itself after 10 seconds, so that if
memcached isn't available, this is the longest that old versions will
hang around.

Test plan:
* work through
  http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11842#c0
  and make sure that the erronious result doesn't occur.

Note:
* The patch on bug 12041 is required for this to work.

Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
C4/Biblio.pm
admin/biblio_framework.pl
admin/koha2marclinks.pl
admin/marc_subfields_structure.pl
admin/marctagstructure.pl