First, congratulations on having so many new members at once that you are crashing Ghost.
You mentioned elsewhere that you have Apache as a reverse proxy in front of Ghost. Review the number of connections that Apache is tuned to support and consider turning that down. I don’t use Apache anymore, but look settings like MaxRequestWorkers
, MaxConnectionsPerChild
and ListenBackLog
and MaxSpareThreads
and MaxSpareServers
. Some of these values may need to be turned /down/. See:
https://httpd.apache.org/docs/2.4/mod/prefork.html#minspareservers
Share your Apache performance tuning settings if you want someone to peer-review.
those.
Enable your Apache server-status page and keep an eye on it to see how your actual workload compares to your settings:
If Apache gets more requests than it is configured to handled, they will be queued according to ListenBacklog. This works sort like the job queue design, in that it effectively queues and throttles the traffic, but without the complexity of adding a job queue. But if you are really sending a massive amount of API traffic at once, then at some point you can’t set your ListenBackLog high enough because even that would run out of memory.Then you need a job queue design to throttle the traffic.