Improve ActionCable reconnection logic
When there are deploys or server restarts, the spike in reconnections cause errors on the server as seen in gitlab-com/gl-infra/production#3477 (closed).
We should improve our client reconnection logic so that our server can handle these reconnections better.
https://github.com/rails/rails/pull/40229 was merged recently to Rails which brings in a lot of improvements to the client:
- The client will wait a random amount between 1x and 3x of the stale threshold after the server's last ping before making the first reconnection attempt.
- Subsequent reconnection attempts now use exponential backoff instead of logarithmic backoff. To allow the delay between reconnection attempts to increase slowly at first, the default exponentiation base is < 2.
- Random jitter is applied to each delay between reconnection attempts.