sashapolo commented on code in PR #7299:
URL: https://github.com/apache/ignite-3/pull/7299#discussion_r2645098574
##########
modules/raft/src/main/java/org/apache/ignite/internal/raft/storage/segstore/SegmentFile.java:
##########
@@ -163,8 +199,35 @@ private void close(byte @Nullable [] bytesToWrite) {
}
}
+ int lastWritePosition() {
+ return lastWritePosition;
+ }
+
+ int syncPosition() {
+ return syncPosition;
+ }
+
void sync() {
- buffer.force();
+ sync(lastWritePosition);
+ }
+
+ private void sync(int upToPosition) {
+ if (syncPosition >= upToPosition) {
Review Comment:
I always get this wrong)
--
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]