[CONTROLLER-2030] Add selectively-bounded implementation of Mailbox to prevent OOM Created: 17/Feb/22  Updated: 06/Jun/23  Resolved: 06/Jun/23

Status: Resolved
Project: controller
Component/s: clustering
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Low
Reporter: Tibor Král Assignee: Tibor Král
Resolution: Won't Do Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

The default mailbox used by Shards is UnboundedDequeBasedControlAwareMailbox.
Having unbounded mailbox can cause OOM issues in scenarious, when the Leader's machine is much faster than Follower's and the Leader is under heavy load. In such case the Leader will replicate changes much faster than the Follower can apply them and thus fill up the Follower's queue to the point of OOM crash. 

It can be solved by an alternative implementation of Mailbox, which can be configured to limit the size of both the Control Queue and Normal Queue if neccessary.


Generated at Wed Feb 07 19:57:02 UTC 2024 using Jira 8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d.