ibessonov commented on code in PR #1226:
URL: https://github.com/apache/ignite-3/pull/1226#discussion_r1003022573
##########
modules/table/src/main/java/org/apache/ignite/internal/table/distributed/raft/snapshot/outgoing/OutgoingSnapshot.java:
##########
@@ -55,7 +288,76 @@ CompletableFuture<SnapshotMvDataResponse>
handleSnapshotMvDataRequest(SnapshotMv
* @param txDataRequest Data request.
*/
CompletableFuture<SnapshotTxDataResponse>
handleSnapshotTxDataRequest(SnapshotTxDataRequest txDataRequest) {
- //TODO https://issues.apache.org/jira/browse/IGNITE-17262
+ //TODO https://issues.apache.org/jira/browse/IGNITE-17935
return null;
}
+
+ /**
+ * Acquires this snapshot lock.
+ */
+ public void acquireLock() {
+ rowOperationsLock.lock();
+ }
+
+ /**
+ * Releases this snapshot lock.
+ */
+ public void releaseLock() {
+ rowOperationsLock.unlock();
+ }
+
+ /**
+ * Whether this snapshot is finished (i.e. it already sent all the MV data
and is not going to send anything else).
+ *
+ * <p>Must be called under snapshot lock.
+ *
+ * @return {@code true} if finished.
+ */
+ public boolean isFinished() {
+ return finished;
+ }
+
+ /**
+ * Adds a {@link RowId} to the collection of IDs that need to be skipped
during normal snapshot row sending.
+ *
+ * <p>Must be called under snapshot lock.
+ *
+ * @param rowId RowId to add.
+ * @return {@code true} if the given RowId was added as it was not yet in
the collection of IDs to skip.
+ */
+ public boolean addOverwrittenRowId(RowId rowId) {
Review Comment:
Second name looks better, and it's short
--
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]