-
Notifications
You must be signed in to change notification settings - Fork 3.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
kvserver: reduce reproposals of AddSSTable and other large commands #98563
Comments
cc @cockroachdb/replication |
Btw I have logging for this in #98576 and it does happen: Details
|
We saw this likely contribute to OOMs during log application in cockroachlabs/support#2287. Touches cockroachdb#98563. Epic: CRDB-25503 Release note: None
I have a (completely untested) prototype here: #106505 Not planning to work on this due to competing priorities. I am also not too convinced this is still a large problem, since CheckQuorum now defaults to on (at least on master) and the cases in which refreshes are problematic have good likelihood to also lose leadership, in which case refreshing adds very little additional work to the system since these proposals just get dropped. I also think there is a more appealing solution (assuming this would still be an issue) which involves preventing proposals when we see evidence that they can't be made to apply. This would be done by proposing an essentially empty command that bumps the lease applied index. The upshot of this strategy is that if we can get that command to apply, we can actually let go completely of the "large" stuck command, i.e. resolve its latches, signal the caller with an unambiguous error, etc. We can also leverage at least partial knowledge of what made it in the raft log, which is possible due to recent refactors (see Footnotes |
We've seen that Raft can run nodes out of memory during overload, in particular with large commands like
AddSSTable
(see e.g. #73376). One possible contributing factor here is reproposals, where an overloaded Raft group that takes more than 3 seconds to ack a proposal may continually stuff the same command into Raft over and over, worsening the overload. We should consider throttling reproposals of large commands.Jira issue: CRDB-25334
Epic CRDB-39898
The text was updated successfully, but these errors were encountered: