[Bug 14315] New: Slow checkouts, caused by many single_holidays definitions
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14315 Bug ID: 14315 Summary: Slow checkouts, caused by many single_holidays definitions Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: normal Priority: P5 - low Component: Circulation Assignee: koha-bugs@lists.koha-community.org Reporter: mtj@kohaaloha.com QA Contact: testopia@bugs.koha-community.org CC: gmcharlt@gmail.com, kyle.m.hall@gmail.com i’ve been poking at a problematic Koha with slow checkout speed, that has around 400 special_holidays defined - only 50 special_holidays are ‘current’. i define ’current’ as holidays that fall after the issue_date, i’ve narrowed the problem down to Koha doing much slow date math on all the holiday rows in the special_holidays table, during a checkout it seems for some situations (like checkouts) Koha only needs to process current holidays, and can safely skip older holidays for processing to me, the most obvious solution seems to be to allow the Koha::Calendar::single_holidays() sub to be passed an ‘issue_date’ arg this would allow single_holidays() to skip any holiday rows older than the $issue_date, for processing Q: is there a better way for single_holidays() to know the issue_date, other than being passed it? i’ve made some hardcoded experiments with the single_holidays() sub skipping old holidays, and seen a 65% improvement to checkout times tested in 3.20.0 -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14315 --- Comment #1 from Mason James <mtj@kohaaloha.com> --- Created attachment 39764 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=39764&action=edit nytprof pic1 -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14315 --- Comment #2 from Mason James <mtj@kohaaloha.com> --- Created attachment 39765 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=39765&action=edit nytprof pic2 -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14315 Mason James <mtj@kohaaloha.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |In Discussion --- Comment #3 from Mason James <mtj@kohaaloha.com> --- attached some nytprof pix -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14315 --- Comment #4 from Mason James <mtj@kohaaloha.com> --- Hmm, one other detail I forgot to add is that the item I was testing with had a circ-rule with a large ‘loan period’ value. The combination of a large number of defined special_holidays (400), and a large ‘loan period’ (280) seems to exacerbate this problem -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14315 Mason James <mtj@kohaaloha.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|koha-bugs@lists.koha-commun |mtj@kohaaloha.com |ity.org | -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14315 --- Comment #5 from Mason James <mtj@kohaaloha.com> --- i've confirmed this problem on master (3.21.00.003), with a similar execution time. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14315 Mason James <mtj@kohaaloha.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Slow checkouts, caused by |Slow checkouts, caused by |many single_holidays |many 'special_holidays' |definitions |definitions -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14315 Mason James <mtj@kohaaloha.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #39765|0 |1 is obsolete| | --- Comment #6 from Mason James <mtj@kohaaloha.com> --- Created attachment 39790 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=39790&action=edit nytprof pic2 oops, attached wrong pic2 file -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14315 Mason James <mtj@kohaaloha.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #39765|1 |0 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14315 Mason James <mtj@kohaaloha.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #39764|0 |1 is obsolete| | --- Comment #7 from Mason James <mtj@kohaaloha.com> --- Comment on attachment 39764 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=39764 nytprof pic1 incorrect file -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14315 Mason James <mtj@kohaaloha.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #39765|nytprof pic2 |nytprof pic1 description| | -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14315 Irma Birchall <irma@calyx.net.au> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |irma@calyx.net.au -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14315 Mason James <mtj@kohaaloha.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |14522 Referenced Bugs: http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14522 [Bug 14522] Use Koha::Cache for accessing single_holidays() -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14315 --- Comment #8 from Mason James <mtj@kohaaloha.com> --- Update: A new bug has been created, that contains a patch for this problem... http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14522 -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org