ibessonov commented on code in PR #7512:
URL: https://github.com/apache/ignite-3/pull/7512#discussion_r2763132666
##########
modules/raft/src/main/java/org/apache/ignite/raft/jraft/core/NodeImpl.java:
##########
@@ -2127,6 +2149,25 @@ public void apply(final Task task) {
throw new IllegalStateException("Node is shutting down");
}
Requires.requireNonNull(task, "Null task");
+ Requires.requireNonNull(task.getData(), "Null data");
+
+ int taskDataSize = task.getData().remaining();
+
+ long maxQueueSize = this.raftOptions.getMaxApplyQueueByteSize();
+
+ if (maxQueueSize > 0) {
+ long currentSize = this.applyQueueByteSize.sum();
+ if (currentSize + taskDataSize > maxQueueSize) {
Review Comment:
Hard to say definitively, GC can't collect the data when we reduce the size
anyway, it's a super-soft limit in these terms.
I don't really get the contention argument, what exactly do you mean by
lock/cas? Increasing the `applyQueueByteSize` does the CAS and works just fine
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]