ibessonov commented on a change in pull request #272:
URL: https://github.com/apache/ignite-3/pull/272#discussion_r689283047



##########
File path: 
modules/table/src/main/java/org/apache/ignite/internal/table/distributed/TableManager.java
##########
@@ -196,21 +196,35 @@ private void createTableLocally(
                 ByteBuffer::compareTo
             );
 
-            partitionMap.put(p, raftMgr.prepareRaftGroup(
+            partitionsGroupsFutures.add(raftMgr.prepareRaftGroup(
                 raftGroupName(tblId, p),
                 assignment.get(p),
                 new PartitionListener(storage)
             ));
         }
 
-        InternalTableImpl internalTable = new InternalTableImpl(name, tblId, 
partitionMap, partitions);
+        
CompletableFuture.allOf(partitionsGroupsFutures.toArray(CompletableFuture[]::new)).thenRun(()
 -> {
+            HashMap<Integer, RaftGroupService> partitionMap = new 
HashMap<>(partitions);

Review comment:
       You replaced map with list in code above but not here. Why?




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


Reply via email to