tmgodinho commented on code in PR #6469:
URL: https://github.com/apache/ignite-3/pull/6469#discussion_r2297698139


##########
modules/network-api/src/main/java/org/apache/ignite/internal/network/IgniteClusterImpl.java:
##########
@@ -31,8 +32,18 @@
 public class IgniteClusterImpl implements IgniteCluster {
     public final TopologyService topologyService;
 
-    public IgniteClusterImpl(TopologyService topologyService) {
+    public final ClusterIdSupplier clusterIdSupplier;
+
+    public IgniteClusterImpl(TopologyService topologyService, 
ClusterIdSupplier clusterIdSupplier) {
         this.topologyService = topologyService;
+        this.clusterIdSupplier = clusterIdSupplier;
+    }
+
+    @Override
+    public UUID clusterId() {
+        @Nullable UUID ret = clusterIdSupplier.clusterId();
+        assert ret != null : "Should not be null";

Review Comment:
   Oh yeah thats right. I meant to ask you if it was possible to connect to a 
node not part of a cluster.
   What do you think is the most correct API in this case?? Allow to return 
null or which exception should be thrown??
   
   I didn't understand exactly the behaviour of `nodes()` when there is no 
cluster. Does it return any error or an empty collection??
   



-- 
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: notifications-unsubscr...@ignite.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to