Bug 17610 - [16.11.x] Allow the number of plack workers and max connections to be set in koha-conf.xml
Summary: [16.11.x] Allow the number of plack workers and max connections to be set in ...
Status: Pushed to Stable
Alias: None
Product: Koha
Classification: Unclassified
Component: Architecture, internals, and plumbing (show other bugs)
Version: master
Hardware: All All
: P5 - low enhancement (vote)
Assignee: Kyle M Hall
QA Contact: Testopia
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-11-10 19:52 UTC by Kyle M Hall
Modified: 2017-11-23 23:25 UTC (History)
6 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
Bug 17610 - Allow the number of plack workers and max connections to be set in koha-conf.xml (2.32 KB, patch)
2016-11-10 19:56 UTC, Kyle M Hall
Details | Diff | Splinter Review
Bug 17610 - Allow the number of plack workers and max connections to be set in koha-conf.xml (2.43 KB, patch)
2016-11-10 20:17 UTC, Kyle M Hall
Details | Diff | Splinter Review
Bug 17610 - Allow the number of plack workers and max connections to be set in koha-conf.xml (2.96 KB, patch)
2016-11-10 20:19 UTC, Kyle M Hall
Details | Diff | Splinter Review
Bug 17610 - Allow the number of plack workers and max connections to be set in koha-conf.xml (3.07 KB, patch)
2016-11-15 13:09 UTC, Kyle M Hall
Details | Diff | Splinter Review
Bug 17610 - Allow the number of plack workers and max connections to be set in koha-conf.xml (3.42 KB, patch)
2017-01-20 14:32 UTC, Tomás Cohen Arazi
Details | Diff | Splinter Review
Bug 17610 - Allow the number of plack workers and max connections to be set in koha-conf.xml (3.47 KB, patch)
2017-01-31 10:53 UTC, Jonathan Druart
Details | Diff | Splinter Review
16.11 - Allow the number of plack workers and max connections to be set in koha-conf.xml (2.23 KB, patch)
2017-06-28 11:05 UTC, Pongtawat
Details | Diff | Splinter Review
Bug 17610 - (16.11.x) Allow the number of plack workers and max connections to be set in koha-conf.xml (2.26 KB, patch)
2017-10-29 21:36 UTC, Josef Moravec
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Kyle M Hall 2016-11-10 19:52:34 UTC
It would be nice if we could control the number of workers and max requests on a per instance basis, rather than the numbers being hardcoded in the plack startup script.
Comment 1 Kyle M Hall 2016-11-10 19:56:10 UTC
Created attachment 57437 [details] [review]
Bug 17610 - Allow the number of plack workers and max connections to be set in koha-conf.xml

It would be nice if we could control the number of workers and max
requests on a per instance basis, rather than the numbers being
hardcoded in the plack startup script.

Test Plan:
1) Build a new package of Koha with this patch applied ; )
2) Verify koha-plack still works
3) Add the following to the config section of your koha-conf.xml:
 <plack_max_requests>75</plack_max_requests>
 <plack_workers>4</plack_workers>
4) Stop plack
5) Start plack
6) Verify the number of works and max requests worked!
Comment 2 Kyle M Hall 2016-11-10 20:17:32 UTC
Created attachment 57438 [details] [review]
Bug 17610 - Allow the number of plack workers and max connections to be set in koha-conf.xml

It would be nice if we could control the number of workers and max
requests on a per instance basis, rather than the numbers being
hardcoded in the plack startup script.

Test Plan:
1) Build a new package of Koha with this patch applied ; )
2) Verify koha-plack still works
3) Add the following to the config section of your koha-conf.xml:
 <plack_max_requests>75</plack_max_requests>
 <plack_workers>4</plack_workers>
4) Stop plack
5) Start plack
6) Verify the number of works and max requests worked!
Comment 3 Kyle M Hall 2016-11-10 20:19:29 UTC
Created attachment 57439 [details] [review]
Bug 17610 - Allow the number of plack workers and max connections to be set in koha-conf.xml

It would be nice if we could control the number of workers and max
requests on a per instance basis, rather than the numbers being
hardcoded in the plack startup script.

Test Plan:
1) Build a new package of Koha with this patch applied ; )
2) Verify koha-plack still works
3) Add the following to the config section of your koha-conf.xml:
 <plack_max_requests>75</plack_max_requests>
 <plack_workers>4</plack_workers>
4) Stop plack
5) Start plack
6) Verify the number of works and max requests worked!
Comment 4 Kyle M Hall 2016-11-15 13:09:57 UTC
Created attachment 57490 [details] [review]
Bug 17610 - Allow the number of plack workers and max connections to be set in koha-conf.xml

It would be nice if we could control the number of workers and max
requests on a per instance basis, rather than the numbers being
hardcoded in the plack startup script.

Test Plan:
1) Build a new package of Koha with this patch applied ; )
2) Verify koha-plack still works
3) Add the following to the config section of your koha-conf.xml:
 <plack_max_requests>75</plack_max_requests>
 <plack_workers>4</plack_workers>
4) Stop plack
5) Start plack
6) Verify the number of works and max requests worked!

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Larry Baerveldt <larry@bywatersolutions.com>
Comment 5 Tomás Cohen Arazi 2016-11-16 18:33:46 UTC
Can we better put that info on a specific file? Maybe /etc/koha/sites/<instance>/plack.conf
Comment 6 Larry Baerveldt 2016-12-30 17:31:47 UTC
I'm curious, but why add a separate config file for what amounts to a couple of lines? Why not just put them on koha-conf.xml?

We desperately need this patch. We're running dozens of sites on our clusters, and need to be able to set different numbers of plack workers for different sites. Plus there are the larger sites on stand-alone servers, that need more than 2 workers, but when we change them in koha-plack, it gets overwritten with every upgrade. This is, in my opinion, a very needed patch.
Comment 7 Marcel de Rooy 2016-12-30 17:44:43 UTC
(In reply to Tomás Cohen Arazi from comment #5)
> Can we better put that info on a specific file? Maybe
> /etc/koha/sites/<instance>/plack.conf

Is that the only reason for Failed QA?
I agree with Larry that they could be in koha-conf, just like similar stuff.
Comment 8 Tomás Cohen Arazi 2016-12-30 17:50:06 UTC
I think we could use this for now, and removed it later.
Comment 9 Marcel de Rooy 2017-01-03 12:51:09 UTC
(In reply to Tomás Cohen Arazi from comment #8)
> I think we could use this for now, and removed it later.

Back to NSO
Comment 10 Tomás Cohen Arazi 2017-01-20 14:32:33 UTC
Created attachment 59377 [details] [review]
Bug 17610 - Allow the number of plack workers and max connections to be set in koha-conf.xml

It would be nice if we could control the number of workers and max
requests on a per instance basis, rather than the numbers being
hardcoded in the plack startup script.

Test Plan:
1) Build a new package of Koha with this patch applied ; )
2) Verify koha-plack still works
3) Add the following to the config section of your koha-conf.xml:
 <plack_max_requests>75</plack_max_requests>
 <plack_workers>4</plack_workers>
4) Stop plack
5) Start plack
6) Verify the number of works and max requests worked!

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Larry Baerveldt <larry@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Rebased against master and added a description for the new configuration
entries
Comment 11 Jonathan Druart 2017-01-31 10:53:15 UTC
Created attachment 59680 [details] [review]
Bug 17610 - Allow the number of plack workers and max connections to be set in koha-conf.xml

It would be nice if we could control the number of workers and max
requests on a per instance basis, rather than the numbers being
hardcoded in the plack startup script.

Test Plan:
1) Build a new package of Koha with this patch applied ; )
2) Verify koha-plack still works
3) Add the following to the config section of your koha-conf.xml:
 <plack_max_requests>75</plack_max_requests>
 <plack_workers>4</plack_workers>
4) Stop plack
5) Start plack
6) Verify the number of works and max requests worked!

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Larry Baerveldt <larry@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Rebased against master and added a description for the new configuration
entries

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Comment 12 Kyle M Hall 2017-01-31 17:20:12 UTC
Pushed to master for 17.05!
Comment 13 Katrin Fischer 2017-02-07 07:12:14 UTC
This won't get ported back to 16.11.x as it is an enhancement.
Comment 14 Pongtawat 2017-06-27 17:28:59 UTC
I would love to see this backported to 16.11 as it would help many installations that still use 16.11 (such as ours). Although this feature is an enhancement, it doesn't conflict with any existing functionality. 

Also, I see that sometimes Koha get enhancement in its point release. For example, 16.11.08 has a new dev_install.
Comment 15 Tomás Cohen Arazi 2017-06-27 17:57:09 UTC
(In reply to Pongtawat from comment #14)
> I would love to see this backported to 16.11 as it would help many
> installations that still use 16.11 (such as ours). Although this feature is
> an enhancement, it doesn't conflict with any existing functionality. 
> 
> Also, I see that sometimes Koha get enhancement in its point release. For
> example, 16.11.08 has a new dev_install.

You should PM Katrin, or contact her on IRC.
Comment 16 Katrin Fischer 2017-06-28 05:55:43 UTC
I just checked, this patch doesn't apply on 16.11.x and I am not confident in fixing the conflicts myself. I am not against backporting this, but need a patch for 16.11.x that is well tested.
Comment 17 Pongtawat 2017-06-28 11:05:28 UTC
Created attachment 64699 [details] [review]
16.11 - Allow the number of plack workers and max connections to be set in koha-conf.xml

Backport to 16.11.x using current code in 17.05.x
Comment 18 Pongtawat 2017-06-28 11:07:40 UTC
Here is my take to backport this patch to 16.11. The code is a bit different than in the previous patch, as it was based on the code currently in 17.05.x branch.

I think it need sign-off?
Comment 19 Katrin Fischer 2017-06-28 21:49:48 UTC
Thx Pongtawat. A sign-off would be great, I am changing the title and status.
Comment 20 Katrin Fischer 2017-07-16 12:58:13 UTC
No string changes, so this could still go into 16.11.10 if signed off on time.
Comment 21 Katrin Fischer 2017-09-10 09:05:01 UTC
Still willing to push this - can we get a sign-off?
Comment 22 Josef Moravec 2017-10-29 21:36:20 UTC
Created attachment 68814 [details] [review]
Bug 17610 - (16.11.x) Allow the number of plack workers and max connections to be set in koha-conf.xml

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Comment 23 Pongtawat 2017-10-30 04:36:11 UTC
Thank you for signing off.
Now I see hope that this might get pushed into the next 16.11 update :)
Comment 24 Marcel de Rooy 2017-11-03 07:54:20 UTC
Moving this one out of the SO queue
Comment 25 Katrin Fischer 2017-11-15 20:26:00 UTC
This has been pushed to 16.11.x and will be in 16.11.14.
Comment 26 Mason James 2017-11-23 23:25:15 UTC
Pushed to 16.05.x, for 16.05.19 release