Open damoon opened 9 months ago
@estahn could you please help with the review and merge here maybe 🙏 The related issue is very actual because it leads to repeating OOM killer alerts
i rebased this to allow for merging. any chance this could be reviewed?
In case the fcgi client does not get a response, without the timeout, it will never free the waitgroup in the Update function and never free the mutex in the Collect function. This stops the metrics endpoint from responding. Requests will get queued until the process gets killed with out of memory. To prevent this, first a timeout was added for the fcgi client and second a timeout and limit was added for the incoming requests.
This issue was also reported in #253.