tkalkirill commented on code in PR #1800:
URL: https://github.com/apache/ignite-3/pull/1800#discussion_r1146329965
##########
modules/storage-api/src/main/java/org/apache/ignite/internal/storage/index/IndexStorage.java:
##########
@@ -54,4 +55,22 @@ public interface IndexStorage {
* @throws StorageException If failed to remove data.
*/
void remove(IndexRow row) throws StorageException;
+
+ /**
+ * Returns the last row ID that has been processed by an ongoing index
build process or {@code null} if the process has finished.
+ *
+ * @throws StorageException If failed to get the last row ID.
+ */
+ @Nullable RowId getLastBuildRowId();
+
+ /**
+ * Sets last row ID for which the index was built, {@code null} means
index building is finished.
+ *
+ * @apiNote This method <b>must</b> always be called inside the
corresponding partition's
+ * {@link
org.apache.ignite.internal.storage.MvPartitionStorage#runConsistently} closure.
+ *
+ * @param rowId Row ID.
+ * @throws StorageException If failed to set the last row ID.
+ */
+ void setLastBuildRowId(@Nullable RowId rowId);
Review Comment:
For example, exceptions are specified in `java.util.Map#containsKey` but not
in the signature, I don’t think that this makes the code better, do you insist?
--
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]