maksaska commented on code in PR #11327:
URL: https://github.com/apache/ignite/pull/11327#discussion_r1580758219


##########
modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java:
##########
@@ -7287,10 +7287,18 @@ private InetSocketAddress 
checkConnection(List<InetSocketAddress> addrs, int tim
                                     sock.connect(addr, perAddrTimeout);
 
                                     liveAddrHolder.compareAndSet(null, addr);
+
+                                    if (log.isInfoEnabled())
+                                        log.info("Successful connection to the 
server [address=" + addr + "]");
+                                }
+                                else if (log.isInfoEnabled()) {
+                                    log.info("Connection to the server 
[address=" + addr + "] is ignored. " +
+                                        "Alive address is found at [address=" 
+ liveAddrHolder.get() + "]");
                                 }
                             }
                             catch (Exception ignored) {
-                                // No-op.
+                                U.warn(log, "Failed to connect the socket to 
the server [address=" + addr +

Review Comment:
   Yes, I agree with you. `checkConnection ` is an utility method. But it 
turned out, that it's the only place, where we have access to connection 
results to all node effective addresses. And the main goal for this 
implementation was to was logs for failed connections, so that we can see the 
reason why they failed, or why they weren't chosen.



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