[Bug 21101] New: Allow to disable XSLT cache
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21101 Bug ID: 21101 Summary: Allow to disable XSLT cache Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: MARC Bibliographic data support Assignee: koha-bugs@lists.koha-community.org Reporter: fridolin.somers@biblibre.com QA Contact: testopia@bugs.koha-community.org Koha::XSLT_Handler has a cache. When Plack is used, the XSLT display have a cache that can last several minutes. This is good for performance but bad for XSLT files edition. I propose a syspref to enable/disable this cache, enabled by default. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21101 Fridolin SOMERS <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff Patch complexity|--- |Trivial patch -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21101 --- Comment #1 from Fridolin SOMERS <fridolin.somers@biblibre.com> --- Created attachment 77180 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=77180&action=edit Bug 21101: Rename engine var in C4::XSLT 'engine' is both a method, used outisde module, and a module shared variable. I rename the variable 'xslth' to avoid confusion and use 'engine()' method inside the module. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21101 --- Comment #2 from Fridolin SOMERS <fridolin.somers@biblibre.com> --- Created attachment 77181 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=77181&action=edit Bug 21101: Allow to disable XSLT cache Koha::XSLT_Handler has a cache. When Plack is used, the XSLT display have a cache that can last several minutes. This is good for performance but bad for XSLT files edition. I propose a syspref to enable/disable this cache, enabled by default. Test plan : 1) Enable Plack 2) Check syspref XSLTCache is enabled 3) Define an XSLT file path in some XSLT display, ie OPACXSLTResultsDisplay 4) Perform a search and look at results 5) Edit XSLT file to add some text, for example next to title 6) Perform a search and look at results => The change is not there, you can try several refresh 7) Undo action 5) 2) Set syspref XSLTCache disabled 8) Perform a search and look at results => you see original display 9) Repeat action 5) 10) Perform a search and look at results => you see the change, you can try several refreshs -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21101 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |m.de.rooy@rijksmuseum.nl --- Comment #3 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Do we really need a pref here? Why? Are these xslt files edited that regularly? If you edit a script, you need to restart Plack. If you edit a XSLT file, just do the same? -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21101 --- Comment #4 from Owen Leonard <oleonard@myacpl.org> --- (In reply to Marcel de Rooy from comment #3)
Do we really need a pref here?
This is the justification I thought of after asking myself the same question: If the XSLT preferences are there to empower the librarian to make their own changes to XSLT, they need a way to test without having server access. Not a very common occurrence, but valid. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21101 Paul Poulain <paul.poulain@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |paul.poulain@biblibre.com --- Comment #5 from Paul Poulain <paul.poulain@biblibre.com> --- Most of our customers have access to XSLT editing (through a webdave space), but they don't have any SSH access. => restarting plack & updating XSLT don't require the same kind of permission. With this dev, a librarian can : * turn the pref ON * play with XSLT and test * once it's OK, turn pref OFF and get caching & performance back. The library is happy and our support team is happy too, one less thing to do :D -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21101 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |tomascohen@gmail.com --- Comment #6 from Tomás Cohen Arazi <tomascohen@gmail.com> --- (In reply to Paul Poulain from comment #5)
Most of our customers have access to XSLT editing (through a webdave space), but they don't have any SSH access. => restarting plack & updating XSLT don't require the same kind of permission. With this dev, a librarian can : * turn the pref ON * play with XSLT and test * once it's OK, turn pref OFF and get caching & performance back.
The library is happy and our support team is happy too, one less thing to do :D
We need a couple 'flush' buttons in about.pl, what do you think? - flush memcached - flush template-toolkit cache - flush XSLT cache -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21101 --- Comment #7 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- (In reply to Tomás Cohen Arazi from comment #6)
We need a couple 'flush' buttons in about.pl, what do you think?
- flush memcached - flush template-toolkit cache - flush XSLT cache
Hmm. This might be better than toggling preferences. Where: About or Administration? The need to flush the XSLT cache separately might be very limited (although supported with $xslt->refresh). If we gracefully(!) restart Plack, we achieve the same and more? -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21101 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |In Discussion --- Comment #8 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Marcel: in the about page :-D -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21101 --- Comment #9 from Fridolin SOMERS <fridolin.somers@biblibre.com> --- (In reply to Marcel de Rooy from comment #7)
(In reply to Tomás Cohen Arazi from comment #6)
We need a couple 'flush' buttons in about.pl, what do you think?
- flush memcached - flush template-toolkit cache - flush XSLT cache
Hmm. This might be better than toggling preferences. Where: About or Administration? The need to flush the XSLT cache separately might be very limited (although supported with $xslt->refresh). If we gracefully(!) restart Plack, we achieve the same and more?
We need at least one for memcached and one for plack. Note that starman has a "reload" option that can be implemented by sending to the starman master pid : /bin/kill -HUP <pid> But I'm still in favor of a syspref because editing XSLT must be done in a lot of steps meaning : - Modify something - Save - Refreshing the HTML page Avoid a step with cache flush is I think the best. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org