You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airavata.apache.org by di...@apache.org on 2021/01/13 03:32:53 UTC

[airavata] branch ssh-pooling-fix created (now 5760d1b)

This is an automated email from the ASF dual-hosted git repository.

dimuthuupe pushed a change to branch ssh-pooling-fix
in repository https://gitbox.apache.org/repos/asf/airavata.git.


      at 5760d1b  Fixing connection validation logic

This branch includes the following new commits:

     new 5760d1b  Fixing connection validation logic

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



[airavata] 01/01: Fixing connection validation logic

Posted by di...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

dimuthuupe pushed a commit to branch ssh-pooling-fix
in repository https://gitbox.apache.org/repos/asf/airavata.git

commit 5760d1ba71ca753c2326112bca3c1ec1a8ea6b79
Author: Dimuthu Wannipurage <di...@gmail.com>
AuthorDate: Tue Jan 12 22:32:38 2021 -0500

    Fixing connection validation logic
---
 .../main/java/org/apache/airavata/helix/adaptor/PoolingSSHJClient.java  | 2 +-
 .../org/apache/airavata/helix/adaptor/wrapper/SFTPClientWrapper.java    | 1 -
 2 files changed, 1 insertion(+), 2 deletions(-)

diff --git a/modules/airavata-helix/agent-impl/sshj-agent/src/main/java/org/apache/airavata/helix/adaptor/PoolingSSHJClient.java b/modules/airavata-helix/agent-impl/sshj-agent/src/main/java/org/apache/airavata/helix/adaptor/PoolingSSHJClient.java
index d7caa29..8010cb5 100644
--- a/modules/airavata-helix/agent-impl/sshj-agent/src/main/java/org/apache/airavata/helix/adaptor/PoolingSSHJClient.java
+++ b/modules/airavata-helix/agent-impl/sshj-agent/src/main/java/org/apache/airavata/helix/adaptor/PoolingSSHJClient.java
@@ -163,7 +163,7 @@ public class PoolingSSHJClient extends SSHClient {
 
                         SSHClientWrapper sshClient = minEntry.getKey();
 
-                        if (!sshClient.isConnected() || !sshClient.isAuthenticated() || !sshClient.isErrored()) {
+                        if (!sshClient.isConnected() || !sshClient.isAuthenticated() || sshClient.isErrored()) {
                             logger.warn("Client for host {} is not connected or not authenticated. Creating a new client", host);
                             removeDisconnectedClients(sshClient, true);
                             return newClientWithSessionValidation();
diff --git a/modules/airavata-helix/agent-impl/sshj-agent/src/main/java/org/apache/airavata/helix/adaptor/wrapper/SFTPClientWrapper.java b/modules/airavata-helix/agent-impl/sshj-agent/src/main/java/org/apache/airavata/helix/adaptor/wrapper/SFTPClientWrapper.java
index 635ddfd..6327d30 100644
--- a/modules/airavata-helix/agent-impl/sshj-agent/src/main/java/org/apache/airavata/helix/adaptor/wrapper/SFTPClientWrapper.java
+++ b/modules/airavata-helix/agent-impl/sshj-agent/src/main/java/org/apache/airavata/helix/adaptor/wrapper/SFTPClientWrapper.java
@@ -25,7 +25,6 @@ import java.io.IOException;
 import java.util.function.Consumer;
 
 public class SFTPClientWrapper extends SFTPClient {
-    private SFTPClient sftpClient;
     private Consumer<Integer> onCloseFunction;
     private SSHClientWrapper originalSSHClient;