[Bug 20116] New: Cache language list
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Bug ID: 20116 Summary: Cache language list Change sponsored?: --- Product: Koha Version: unspecified Hardware: All OS: All Status: ASSIGNED Severity: enhancement Priority: P5 - low Component: Architecture, internals, and plumbing Assignee: jonathan.druart@bugs.koha-community.org Reporter: jonathan.druart@bugs.koha-community.org QA Contact: testopia@bugs.koha-community.org Depends on: 20115 C4::Languages::getTranslatedLanguages calls _get_language_dirs that list directories to know the available themes. It sounds like we could avoid that and cache it instead. Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20115 [Bug 20115] Languages appear in a different order in the footer -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #1 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 71097 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=71097&action=edit Bug 20116: Prepare the ground Just refactoring to make the next patch more readable -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #2 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 71098 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=71098&action=edit Bug 20116: Cache language list -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #3 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Do these patches make sense? It seems that some call to getTranslatedLanguages are wrong: 1. members/memberentry.pl: my $translated_languages = C4::Languages::getTranslatedLanguages( 'opac', C4::Context->preference('template') ); # template is for the intranet, we should use opacthemes instead 2. tools/letter.pl 159 my $translated_languages = 160 C4::Languages::getTranslatedLanguages( 'opac', 161 C4::Context->preference('template') ); Additional note: "template" and "opacthemes" are confusing, the same terms must be used -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #4 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- TODO: We should add a warning to koha-translate to restart memcached (or better, clear only what is needed) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |7923 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7923 [Bug 7923] Performance omnibus -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #5 from M. Tompsett <mtompset@hotmail.com> --- Comment on attachment 71098 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=71098 Bug 20116: Cache language list Review of attachment 71098: --> (https://bugs.koha-community.org/bugzilla3/page.cgi?id=splinter.html&bug=20116&attachment=71098) ----------------------------------------------------------------- ::: C4/Languages.pm @@ +122,3 @@
if ($interface && $interface eq 'opac' ) { my $htdocs = C4::Context->config('opachtdocs'); @languages = _get_opac_language_dirs( $htdocs, $theme );
Forgot to delete this line, I think. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #71098|0 |1 is obsolete| | --- Comment #6 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 73521 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=73521&action=edit Bug 20116: Cache language list -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #7 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- (In reply to M. Tompsett from comment #5)
Comment on attachment 71098 [details] [review] Bug 20116: Cache language list
Review of attachment 71098 [details] [review]: -----------------------------------------------------------------
::: C4/Languages.pm @@ +122,3 @@
if ($interface && $interface eq 'opac' ) { my $htdocs = C4::Context->config('opachtdocs'); @languages = _get_opac_language_dirs( $htdocs, $theme );
Forgot to delete this line, I think.
Indeed, thanks for catching it! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #8 from Josef Moravec <josef.moravec@gmail.com> --- Comment on attachment 71097 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=71097 Bug 20116: Prepare the ground Review of attachment 71097: --> (https://bugs.koha-community.org/bugzilla3/page.cgi?id=splinter.html&bug=20116&attachment=71097) ----------------------------------------------------------------- ::: C4/Languages.pm @@ +132,3 @@
$htdocs = C4::Context->config('opachtdocs'); + push @languages, _get_intranet_opac_dirs( $htdocs ); +
should be _get_opac_language_dirs -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Josef Moravec <josef.moravec@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Failed QA CC| |josef.moravec@gmail.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #71097|0 |1 is obsolete| | Attachment #73521|0 |1 is obsolete| | --- Comment #9 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 73619 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=73619&action=edit Bug 20116: Prepare the ground Just refactoring to make the next patch more readable -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #10 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 73620 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=73620&action=edit Bug 20116: Cache language list -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #11 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- (In reply to Josef Moravec from comment #8)
Comment on attachment 71097 [details] [review] Bug 20116: Prepare the ground
Review of attachment 71097 [details] [review]: -----------------------------------------------------------------
::: C4/Languages.pm @@ +132,3 @@
$htdocs = C4::Context->config('opachtdocs'); + push @languages, _get_intranet_opac_dirs( $htdocs ); +
should be _get_opac_language_dirs
Erk, thanks! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |julian.maurice@biblibre.com | |, tomascohen@gmail.com Keywords| |rel_18_05_candidate -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords|rel_18_05_candidate | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #73619|0 |1 is obsolete| | Attachment #73620|0 |1 is obsolete| | --- Comment #12 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 75382 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=75382&action=edit Bug 20116: Prepare the ground Just refactoring to make the next patch more readable -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #13 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 75383 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=75383&action=edit Bug 20116: Cache language list -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #14 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 75384 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=75384&action=edit Bug 20116: Flush the caches When languages are added or removed when need to flush the caches to keep the interface consistent -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #75383|0 |1 is obsolete| | --- Comment #15 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 75385 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=75385&action=edit Bug 20116: Cache language list -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #16 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Before the patches, C4::Languages::getTranslatedLanguages('intranet', 'prog') took between 0.002 and 0.003s Now it's 0.0015s (and I guess the difference can be much better when hundred of queries are made at the same time). -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #17 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- (Of course first hit is worse) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #18 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Jonathan, it looks great. Will you provide a couple tests for this? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #19 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- (In reply to Tomás Cohen Arazi from comment #18)
Jonathan, it looks great. Will you provide a couple tests for this?
I do not think it can be done easily, any ideas? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Bug 20116 depends on bug 20115, which changed state. Bug 20115 Summary: Languages appear in a different order in the footer https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20115 What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to Stable |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Liz Rea <wizzyrea@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |wizzyrea@gmail.com --- Comment #20 from Liz Rea <wizzyrea@gmail.com> --- I don't know if this matters - I gave this a go in a devbox, copied all the files in where they needed to be etc etc, and got this on a koha-translate --install de-DE: Connection to the memcached servers '__MEMCACHED_SERVERS__' failed. Are the unix socket permissions set properly? Is the host reachable? If you ignore this warning, you will face performance issues Connection to the memcached servers '__MEMCACHED_SERVERS__' failed. Are the unix socket permissions set properly? Is the host reachable? If you ignore this warning, you will face performance issues Now, I realise that may be because this feature wasn't installed as part of the package and thusly some data might not have been subbed in like it was supposed to be and this will work fine when it's installed properly via apt. If you think this is OK, I'll sign off on it. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #21 from Liz Rea <wizzyrea@gmail.com> --- Had a talk with Tomas, he thinks this is fine so I"ll attach a signed off one for QA to have a look at. Liz -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Liz Rea <wizzyrea@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Liz Rea <wizzyrea@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #75382|0 |1 is obsolete| | Attachment #75384|0 |1 is obsolete| | Attachment #75385|0 |1 is obsolete| | --- Comment #22 from Liz Rea <wizzyrea@gmail.com> --- Created attachment 88200 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=88200&action=edit Bug 20116: Prepare the ground Just refactoring to make the next patch more readable Signed-off-by: Liz Rea <wizzyrea@gmail.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #23 from Liz Rea <wizzyrea@gmail.com> --- Created attachment 88201 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=88201&action=edit Bug 20116: Flush the caches When languages are added or removed when need to flush the caches to keep the interface consistent Signed-off-by: Liz Rea <wizzyrea@gmail.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #24 from Liz Rea <wizzyrea@gmail.com> --- Created attachment 88202 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=88202&action=edit Bug 20116: Cache language list Signed-off-by: Liz Rea <wizzyrea@gmail.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |m.de.rooy@rijksmuseum.nl --- Comment #25 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- + my @enabled_languages = + ( $interface && $interface eq 'intranet' ) + ? split ",", C4::Context->preference('language') + : split ",", C4::Context->preference('opaclanguage'); Seems to reverse the previous logic. If eq opac then opac else intranet. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #26 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- (In reply to Marcel de Rooy from comment #25)
+ my @enabled_languages = + ( $interface && $interface eq 'intranet' ) + ? split ",", C4::Context->preference('language') + : split ",", C4::Context->preference('opaclanguage');
Seems to reverse the previous logic. If eq opac then opac else intranet.
I do not think I get that one, please read again the whole diff: before: if $interface == opac: use opaclanguages elsif $interface == intranet: use language else: use opaclanguages after: if $interface == intranet: use language else: use opaclanguages Looks equal for me. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #27 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- (In reply to Jonathan Druart from comment #26)
(In reply to Marcel de Rooy from comment #25)
+ my @enabled_languages = + ( $interface && $interface eq 'intranet' ) + ? split ",", C4::Context->preference('language') + : split ",", C4::Context->preference('opaclanguage');
Seems to reverse the previous logic. If eq opac then opac else intranet.
I do not think I get that one, please read again the whole diff:
before: if $interface == opac: use opaclanguages elsif $interface == intranet: use language else: use opaclanguages
after: if $interface == intranet: use language else: use opaclanguages
Looks equal for me.
Seems so. OK -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA --- Comment #28 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Hmm What about adding a few tests now? :) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #29 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- (In reply to Jonathan Druart from comment #19)
(In reply to Tomás Cohen Arazi from comment #18)
Jonathan, it looks great. Will you provide a couple tests for this?
I do not think it can be done easily, any ideas?
iirc other subs also are tested with mocking cache -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- QA Contact|testopia@bugs.koha-communit |m.de.rooy@rijksmuseum.nl |y.org | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #30 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Hi Marcel, I have still no idea how to write useful tests for this change, can you give me more details please? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #31 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- (In reply to Jonathan Druart from comment #30)
Hi Marcel, I have still no idea how to write useful tests for this change, can you give me more details please?
Mock the directory structure too where Koha looks for languages. Remove entries from the cache, etc. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #32 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- I do not see the point of those tests. The patches are just caching a value, there is nothing to prove. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Guillaume <guillaume@terreau.eu> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |guillaume@terreau.eu --- Comment #33 from Guillaume <guillaume@terreau.eu> --- I have same problem on fresh install in Debian 9.9 last version. After installation : when launch koha-translate --install fr-FR Connection to the memcached servers '__MEMCACHED_SERVERS__' failed. Are the unix socket permissions set properly? Is the host reachable? If you ignore this warning, you will face performance issues Connection to the memcached servers '__MEMCACHED_SERVERS__' failed. Are the unix socket permissions set properly? Is the host reachable? If you ignore this warning, you will face performance issues Use of uninitialized value $pref_name in concatenation (.) or string at /usr/share/koha/misc/translator/LangInstaller.pm line 197. Use of uninitialized value $pref_name in concatenation (.) or string at /usr/share/koha/misc/translator/LangInstaller.pm line 239. memcached working: # systemctl status memcached.service â memcached.service - memcached daemon Loaded: loaded (/lib/systemd/system/memcached.service; enabled; vendor preset: enabled) Active: active (running) since Sun 2019-05-12 20:12:52 CEST; 1min 34s ago Docs: man:memcached(1) Main PID: 621 (memcached) Tasks: 7 (limit: 4915) CGroup: /system.slice/memcached.service ââ621 /usr/bin/memcached -m 64 -p 11211 -u memcache -l 127.0.0.1 mai 12 20:12:52 kohaDebian9 systemd[1]: Started memcached daemon. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #34 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- (In reply to Guillaume from comment #33) Hello Guillaume, Edit $KOHA_CONF and search for "__MEMCACHED_SERVERS__", replace it with "127.0.0.1:11211" or adjust depending on your needs. If it still does not work, please ask the list, this is more a support question. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #35 from Guillaume <guillaume@terreau.eu> --- in file /etc/koha/koha-sites.conf in find MEMCACHED_SERVERS="127.0.0.1:11211" and in configuration MEMCACHED is on this server: systemctl status memcached.service â memcached.service - memcached daemon Loaded: loaded (/lib/systemd/system/memcached.service; enabled; vendor preset Active: active (running) since Mon 2019-05-13 19:44:21 CEST; 3min 57s ago Docs: man:memcached(1) Main PID: 632 (memcached) Tasks: 7 (limit: 4915) CGroup: /system.slice/memcached.service ââ632 /usr/bin/memcached -m 128 -p 11211 -u memcache -l 127.0.0.1 in witch file is the "__MEMCACHED_SERVERS__" i find not it. Sorry it's my 1st installation of Koha I am testing the software and need french translation. Did I reinstall with Ubunutu 16.04 - >i can do it, i am installing in a VM on ESXI What file is for you $KOHA_CONF in /etc/koha/sites/kohadebian9/koha-conf.xml i find <memcached_servers>127.0.0.1:11211</memcached_servers> <memcached_namespace>koha_kohadebian9</memcached_namespace> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #36 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- (In reply to Guillaume from comment #35)
in file /etc/koha/koha-sites.conf in find MEMCACHED_SERVERS="127.0.0.1:11211"
and in configuration MEMCACHED is on this server:
systemctl status memcached.service â memcached.service - memcached daemon Loaded: loaded (/lib/systemd/system/memcached.service; enabled; vendor preset Active: active (running) since Mon 2019-05-13 19:44:21 CEST; 3min 57s ago Docs: man:memcached(1) Main PID: 632 (memcached) Tasks: 7 (limit: 4915) CGroup: /system.slice/memcached.service ââ632 /usr/bin/memcached -m 128 -p 11211 -u memcache -l 127.0.0.1
in witch file is the "__MEMCACHED_SERVERS__" i find not it.
Sorry it's my 1st installation of Koha I am testing the software and need french translation.
Did I reinstall with Ubunutu 16.04 - >i can do it, i am installing in a VM on ESXI
What file is for you $KOHA_CONF
in /etc/koha/sites/kohadebian9/koha-conf.xml
i find
<memcached_servers>127.0.0.1:11211</memcached_servers> <memcached_namespace>koha_kohadebian9</memcached_namespace>
Guillaume, you will not get support here. You should ask the koha-devel list: http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-devel Or the general mailing list: https://lists.katipo.co.nz/mailman/listinfo/koha -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Signed Off --- Comment #37 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Asking for another QA feedback. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #38 from M. Tompsett <mtompset@hotmail.com> --- Comment on attachment 88201 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=88201 Bug 20116: Flush the caches Review of attachment 88201: --> (https://bugs.koha-community.org/bugzilla3/page.cgi?id=splinter.html&bug=20116&attachment=88201) ----------------------------------------------------------------- ::: debian/scripts/koha-translate @@ +233,5 @@
+flush_cache() +{ + if [ "$dev" = "" ]; then + koha-foreach --enabled "$KOHA_HOME/misc/bin/clear_cache.pl"
Is $KOHA_HOME/misc/bin going to exist? And is clear_cache.pl going to get put there? Something is fishy for running this live. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 M. Tompsett <mtompset@hotmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |mtompset@hotmail.com Status|Signed Off |Failed QA --- Comment #39 from M. Tompsett <mtompset@hotmail.com> --- In addition to the whole $KOHA_HOME path existing in live problem, perhaps the flushing could be split to a separate patch, so that bug 20884 could depend on that, and not this? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 M. Tompsett <mtompset@hotmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=20884 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #40 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- (In reply to M. Tompsett from comment #38)
Comment on attachment 88201 [details] [review] Bug 20116: Flush the caches
Review of attachment 88201 [details] [review]: -----------------------------------------------------------------
::: debian/scripts/koha-translate @@ +233,5 @@
+flush_cache() +{ + if [ "$dev" = "" ]; then + koha-foreach --enabled "$KOHA_HOME/misc/bin/clear_cache.pl"
Is $KOHA_HOME/misc/bin going to exist? And is clear_cache.pl going to get put there? Something is fishy for running this live.
How that? Did you `git grep KOHA_HOME`? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #41 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- (In reply to M. Tompsett from comment #39)
In addition to the whole $KOHA_HOME path existing in live problem, perhaps the flushing could be split to a separate patch, so that bug 20884 could depend on that, and not this?
Or we push this and bug 20884 will benefit from it? :) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Signed Off --- Comment #42 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Still waiting for another QA feedback, back to NQA. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA --- Comment #43 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- (In reply to Jonathan Druart from comment #42)
Still waiting for another QA feedback, back to NQA.
I am still hoping for tests :) Note even that this patch set breaks a test when these patches are applied and does not when not. t/db_dependent/Languages.t (Wstat: 512 Tests: 18 Failed: 2) Failed tests: 11, 13 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #88200|0 |1 is obsolete| | Attachment #88201|0 |1 is obsolete| | Attachment #88202|0 |1 is obsolete| | --- Comment #44 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 94995 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=94995&action=edit Bug 20116: Prepare the ground Just refactoring to make the next patch more readable Signed-off-by: Liz Rea <wizzyrea@gmail.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #45 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 94996 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=94996&action=edit Bug 20116: Flush the caches When languages are added or removed when need to flush the caches to keep the interface consistent Signed-off-by: Liz Rea <wizzyrea@gmail.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #46 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 94997 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=94997&action=edit Bug 20116: Cache language list Signed-off-by: Liz Rea <wizzyrea@gmail.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #47 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- (In reply to Marcel de Rooy from comment #43)
(In reply to Jonathan Druart from comment #42)
Still waiting for another QA feedback, back to NQA.
I am still hoping for tests :)
Hi Marcel, Yes I know, but I still not know how to write them usefully. I switched back to SO to get the point of view of an other QAer. See comments 28 to 32.
Note even that this patch set breaks a test when these patches are applied and does not when not.
t/db_dependent/Languages.t (Wstat: 512 Tests: 18 Failed: 2) Failed tests: 11, 13
Thanks for catching that, fixed. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |katrin.fischer@bsz-bw.de Status|Signed Off |Failed QA --- Comment #48 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- I tried testing this, not sure if what I saw is to be expected: sudo koha-translate --update de-DE --dev kohadev German is updated, activated via sysprefs sudo koha-translate --remove de-DE --dev kohadev sudo koha-translate --list --dev kohadev Only shows inactive fr-FR. But: In the OPAC German is still visible and only disappears when I run restart_all. I reinstalled the language: sudo koha-translate --install de-DE --dev kohadev As an additional find, searching the language preferences from the German interface exploded in an error (search for langu): Can't use an undefined value as an ARRAY reference at /usr/lib/x86_64-linux-gnu/perl5/5.24/YAML/Syck.pm line 76 Jonathan, can you have a look? Just switching to FQA temporarily. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Signed Off --- Comment #49 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Hi Katrin, My bet is that you tested without the correct koha-translate file. Are you sure you copied the one patched with this change? You can use reset_all to make sure it will be copied. Tested right now and it works as expected. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #50 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- That's correct, I didn't copy the file. From where to where do you have to copy it? A test plan would be helpful. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #51 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- (In reply to Katrin Fischer from comment #50)
That's correct, I didn't copy the file. From where to where do you have to copy it? A test plan would be helpful.
Koha scripts are in /usr/sbin/koha-translate (`which koha-translate` tell you where it is). A test plan could be: 0/ Apply the patch and `reset_all` 1/ Install languages, enable them at staff and OPAC 2/ Confirm you have the languages listed at the bottom 3/ Uninstall one language 4/ Confirm that it does not longer appear in the language at the bottom of the pages and in the prefs Also play with koha-translate --install, --remove and --list Additionally, QA will make sure that the changes make sense. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Bouzid Fergani <bouzid.fergani@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #94995|0 |1 is obsolete| | --- Comment #52 from Bouzid Fergani <bouzid.fergani@inlibro.com> --- Created attachment 99431 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=99431&action=edit Bug 20116: Prepare the ground Just refactoring to make the next patch more readable Signed-off-by: Liz Rea <wizzyrea@gmail.com> Signed-off-by: Bouzid Fergani <bouzid.fergani@inlibro.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Bouzid Fergani <bouzid.fergani@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #94996|0 |1 is obsolete| | --- Comment #53 from Bouzid Fergani <bouzid.fergani@inlibro.com> --- Created attachment 99432 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=99432&action=edit Bug 20116: Flush the caches When languages are added or removed when need to flush the caches to keep the interface consistent Signed-off-by: Liz Rea <wizzyrea@gmail.com> Signed-off-by: Bouzid Fergani <bouzid.fergani@inlibro.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Bouzid Fergani <bouzid.fergani@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #94997|0 |1 is obsolete| | --- Comment #54 from Bouzid Fergani <bouzid.fergani@inlibro.com> --- Created attachment 99433 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=99433&action=edit Bug 20116: Cache language list Signed-off-by: Liz Rea <wizzyrea@gmail.com> Signed-off-by: Bouzid Fergani <bouzid.fergani@inlibro.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |BLOCKED --- Comment #55 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- QAing -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Patch complexity|--- |Small patch Status|BLOCKED |Passed QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #99431|0 |1 is obsolete| | --- Comment #56 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 103007 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=103007&action=edit Bug 20116: Prepare the ground Just refactoring to make the next patch more readable Signed-off-by: Liz Rea <wizzyrea@gmail.com> Signed-off-by: Bouzid Fergani <bouzid.fergani@inlibro.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #99432|0 |1 is obsolete| | --- Comment #57 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 103008 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=103008&action=edit Bug 20116: Flush the caches When languages are added or removed when need to flush the caches to keep the interface consistent Signed-off-by: Liz Rea <wizzyrea@gmail.com> Signed-off-by: Bouzid Fergani <bouzid.fergani@inlibro.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #99433|0 |1 is obsolete| | --- Comment #58 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 103009 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=103009&action=edit Bug 20116: Cache language list Signed-off-by: Liz Rea <wizzyrea@gmail.com> Signed-off-by: Bouzid Fergani <bouzid.fergani@inlibro.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to master Version(s)| |20.05.00 released in| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #59 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Nice work everyone! Pushed to master for 20.05 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Joy Nelson <joy@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |joy@bywatersolutions.com --- Comment #60 from Joy Nelson <joy@bywatersolutions.com> --- enhancement not backported to 19.11.x -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |martin.renvoize@ptfs-europe | |.com Summary|Cache language list |Improve performance by | |caching the language list -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #61 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- On a package install I get: root@koha-debian10:~# koha-translate --install es-ES /bin/bash: /usr/share/koha/misc/bin/clear_cache.pl: No such file or directory The script is in /usr/share/koha/bin/clear_cache.pl -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #62 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 105359 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=105359&action=edit Bug 20116: Fix package install path for clear_cache.pl root@koha-debian10:~# koha-translate --install es-ES /bin/bash: /usr/share/koha/misc/bin/clear_cache.pl: No such file or directory The script is in /usr/share/koha/bin/clear_cache.pl -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 --- Comment #63 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Last patch pushed to master for 20.05 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20116 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |dcook@prosentient.com.au -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org