valepakh commented on code in PR #1991:
URL: https://github.com/apache/ignite-3/pull/1991#discussion_r1186172671


##########
modules/cluster-management/src/main/java/org/apache/ignite/internal/cluster/management/ClusterManagementGroupManager.java:
##########
@@ -406,24 +403,22 @@ private void onElectedAsLeader(long term) {
                     }
                 });
 
-        
raftServiceAfterJoin().thenCompose(this::pushAuthenticationConfigToCluster);
+        raftServiceAfterJoin().thenCompose(this::pushClusterConfigToCluster);
     }
 
-    private CompletableFuture<Void> 
pushAuthenticationConfigToCluster(CmgRaftService service) {
+    private CompletableFuture<Void> pushClusterConfigToCluster(CmgRaftService 
service) {
         return service.readClusterState()
                 .thenCompose(state -> {
                     if (state == null) {
-                        LOG.info("No CMG state found in the Raft storage");
+                        LOG.info("No CMG state found in the Raft service");
                         return completedFuture(null);
-                    } else if (state.restAuthToApply() == null) {
-                        // auth config has already been successfully pushed to 
the distributed configuration
-                        LOG.info("No REST auth configuration found in the Raft 
storage");
+                    } else if (state.clusterConfigurationToApply() == null) {
+                        // Config was applied or wasn't provided
+                        LOG.info("No cluster configuration found in the Raft 
service");
                         return completedFuture(null);
                     } else {
-                        //TODO 
https://issues.apache.org/jira/browse/IGNITE-19077
-                        LOG.info("REST auth configuration found in the Raft 
storage, going to apply it");
-                        Authentication restAuthToApply = 
state.restAuthToApply();
-                        return 
distributedConfigurationUpdater.updateRestAuthConfiguration(restAuthToApply)
+                        LOG.info("Cluster configuration is found in the Raft 
service, going to apply it");
+                        return 
distributedConfigurationUpdater.updateConfiguration(state.clusterConfigurationToApply())
                                 .thenCompose(unused -> 
removeAuthConfigFromClusterState(service));

Review Comment:
   `removeAuthConfigFromClusterState` should be renamed



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