Cherry picks the commit from #295 back to our ficus branch.
Since we've now encountered memory/resource leak problems a few times
that have been fixed by setting the max_requests for gunicorn and
have not seen any negative effects, set a reasonable default for the
value.
With it unset, it defaults to 0, which gunicorn interprets as "never
restart workers" and if a server gets enough traffic or runs long
enough can eventually cause memory or resource leak problems.
Tahoe, OU Ginkgo, and now PSU have been running with it set to 1000
for a while now (more than a year in Tahoe's case) and we haven't seen
any problems as a result, so this should be a reasonable default
value. And of course, it can still be overridden in server-vars.yml
if we ever need that.
Cherry picks the commit from #295 back to our ficus branch.
Since we've now encountered memory/resource leak problems a few times that have been fixed by setting the
max_requests
for gunicorn and have not seen any negative effects, set a reasonable default for the value.With it unset, it defaults to
0
, which gunicorn interprets as "never restart workers" and if a server gets enough traffic or runs long enough can eventually cause memory or resource leak problems.Tahoe, OU Ginkgo, and now PSU have been running with it set to
1000
for a while now (more than a year in Tahoe's case) and we haven't seen any problems as a result, so this should be a reasonable default value. And of course, it can still be overridden inserver-vars.yml
if we ever need that.