ignite-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [ignite] isapego commented on a change in pull request #6595: IGNITE-11685 Java thin client: Handle multiple async requests in parallel
Date Thu, 04 Jul 2019 14:30:49 GMT
isapego commented on a change in pull request #6595: IGNITE-11685 Java thin client: Handle
multiple async requests in parallel
URL: https://github.com/apache/ignite/pull/6595#discussion_r300419535
 
 

 ##########
 File path: modules/core/src/main/java/org/apache/ignite/internal/client/thin/ReliableChannel.java
 ##########
 @@ -80,32 +76,34 @@
 
         List<InetSocketAddress> addrs = parseAddresses(clientCfg.getAddresses());
 
+        srvCnt = addrs.size();
+
         primary = addrs.get(new Random().nextInt(addrs.size())); // we already verified there
is at least one address
 
         for (InetSocketAddress a : addrs) {
             if (a != primary)
-                this.backups.add(a);
+                backups.add(a);
         }
 
         ClientConnectionException lastEx = null;
 
         for (int i = 0; i < addrs.size(); i++) {
             try {
-                ch = chFactory.apply(new ClientChannelConfiguration(clientCfg).setAddress(primary)).get();
+                ch = chFactory.apply(new ClientChannelConfiguration(clientCfg).setAddress(addrs.get(i))).get();
 
 Review comment:
   Does Java thin client throw an exception if it can not establish connection to one of nodes?

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

Mime
View raw message