Bug 16067 - Koha::Cache, fastmmap caching system is broken
Summary: Koha::Cache, fastmmap caching system is broken
Status: NEW
Alias: None
Product: Koha
Classification: Unclassified
Component: Architecture, internals, and plumbing (show other bugs)
Version: master
Hardware: All All
: P5 - low enhancement (vote)
Assignee: Galen Charlton
QA Contact: Testopia
URL:
Whiteboard:
Keywords:
Depends on: 11998
Blocks:
  Show dependency treegraph
 
Reported: 2016-03-14 16:32 UTC by Jacek Ablewicz
Modified: 2018-05-04 05:42 UTC (History)
4 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Bot Control: ---
When did the bot last check this:
Who signed the patch off:
Text to go in the release notes:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jacek Ablewicz 2016-03-14 16:32:24 UTC
After Bug 11998, fastmmap caching system implementation in Koha::Cache ceased to work properly. If fastmmap is enabled (= environment variable CACHING_SYSTEM is set to 'fastmmap'), any CGI script call causes the following error:

Use of uninitialized value $db_name in concatenation (.) or string at /home/koha/devkohaclone/Koha/Database.pm line 73.
Use of uninitialized value $db_host in concatenation (.) or string at /home/koha/devkohaclone/Koha/Database.pm line 73.
DBI connect('database=;host=;port=','',...) failed: Access denied for user 'koha'@'localhost' (using password: NO) at /usr/share/perl5/DBIx/Class/Storage/DBI.pm line 1249
DBIx::Class::Storage::DBI::dbh(): DBI Connection failed: Access denied for user 'koha'@'localhost' (using password: NO) at /usr/share/perl5/DBIx/Class/Storage/DBI.pm line 1253. at /home/koha/devkohaclone/Koha/Database.pm line 90

To reproduce on command line:

0) ensure that you have fastmmap perl module installed (libcache-fastmmap-perl in debian)
1) export CACHING_SYSTEM=fastmmap
2) export GATEWAY_INTERFACE=1
3) try to run this simple script:

#!/usr/bin/perl

use Modern::Perl;
use C4::Biblio;
GetMarcStructure();
Comment 1 Jacek Ablewicz 2016-03-14 16:38:08 UTC
See also: Bug 11998 comments #114 - #123
Comment 2 Jacek Ablewicz 2016-03-14 16:47:55 UTC
Personally, I opt for leaving it as is (i.e. broken) for the time being. At least that way we will gather some info regarding prevalence of this caching system in real-world koha installations ;)
Comment 3 Martin Renvoize 2016-03-15 06:36:33 UTC
I've been asking myself the question of 'whose using all these different caching systems?' for a while now. We seem to needlessly complicate our caching by supporting so many options (and we even removed the use of CHI to do it!)

+1 for leave it broken, then maybe we'll actually find someone who might be using it ;)
Comment 4 Jonathan Druart 2016-03-15 09:15:51 UTC
(In reply to Jacek Ablewicz from comment #2)
> Personally, I opt for leaving it as is (i.e. broken) for the time being. At
> least that way we will gather some info regarding prevalence of this caching
> system in real-world koha installations ;)

It's a bit rude but I totally support this idea.
Comment 5 Marcel de Rooy 2018-05-03 13:10:19 UTC
Cant we get information about that via HEA? Although HEA is not complete of course, but to be rude too if you do not join HEA, do not complain that we did not know that you were still using it..
Comment 6 Katrin Fischer 2018-05-04 05:42:54 UTC
(In reply to Marcel de Rooy from comment #5)
> Cant we get information about that via HEA? Although HEA is not complete of
> course, but to be rude too if you do not join HEA, do not complain that we
> did not know that you were still using it..

Hea can only show what we built into it to show... we'd need to add information about caching and then wait for people to actually update.

If it's broken, why not deprecate it with a note in the release notes? Are good reasons someone would not just switch to a better (memcached?) one?