tkalkirill commented on a change in pull request #8962:
URL: https://github.com/apache/ignite/pull/8962#discussion_r607599997



##########
File path: 
modules/core/src/main/java/org/apache/ignite/internal/managers/indexing/IndexesRebuildTask.java
##########
@@ -38,19 +38,22 @@
 import org.apache.ignite.internal.util.typedef.internal.U;
 import org.jetbrains.annotations.Nullable;
 
-import static java.util.Objects.isNull;
-import static java.util.Objects.nonNull;
-
 /**
  * Task that rebuilds indexes.
  */
 public class IndexesRebuildTask {
     /** Index rebuilding futures for caches. Mapping: cacheId -> rebuild 
indexes future. */
     private final Map<Integer, SchemaIndexCacheFuture> idxRebuildFuts = new 
ConcurrentHashMap<>();
 
-    /** Start to rebuild. */
-    public IgniteInternalFuture<?> rebuild(GridCacheContext cctx) {
-        assert nonNull(cctx);
+    /**
+     * Start to rebuild.
+     *
+     * @param cctx Cache context.
+     * @param force Force rebuild indexes.
+     * @return A future of rebuilding cache indexes.
+     */
+    @Nullable public IgniteInternalFuture<?> rebuild(GridCacheContext cctx, 
boolean force) {
+        assert cctx != null;
 
         if (!CU.affinityNode(cctx.localNode(), cctx.config().getNodeFilter()))

Review comment:
       I propose to leave it as it is, it seems that the completed future means 
that the rebuilding began and ended, which is not true.




-- 
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.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to