Skip to content

Commit 2a610ff

Browse files
Artem LabazinArtem Labazin
authored andcommitted
Fix exception handling
1 parent b1c9327 commit 2a610ff

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

encon/src/main/java/io/appulse/encon/ModulePing.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,10 +64,10 @@ boolean ping (@NonNull RemoteNode remote) {
6464
Connection connection = null;
6565
try {
6666
connection = node.connect(remote);
67-
} catch (TimeoutException ex) {
68-
log.error("Remote node timeout exception");
67+
} catch (Exception ex) {
68+
log.error("Error during node {} connection", remote, ex);
6969
}
70-
if (node.connect(remote) == null) {
70+
if (connection == null) {
7171
log.debug("Remote node {} is not available", remote);
7272
return false;
7373
}

0 commit comments

Comments
 (0)