Skip to content

Commit

Permalink
Merge branch '3.7-dev'
Browse files Browse the repository at this point in the history
  • Loading branch information
spmallette committed Jun 19, 2024
2 parents bb4fccd + dc6e715 commit 9bddde4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -351,6 +351,7 @@ image::https://raw.githubusercontent.com/apache/tinkerpop/master/docs/static/ima
=== TinkerPop 3.6.8 (NOT OFFICIALLY RELEASED YET)
* Fixed bug in Java driver where connection pool was not removing dead connections under certain error conditions.
* Raised handshake exceptions for Java driver for `NoHostAvailableException` situations.
[[release-3-6-7]]
=== TinkerPop 3.6.7 (April 8, 2024)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
*/
package org.apache.tinkerpop.gremlin.driver;

import io.netty.handler.codec.http.websocketx.WebSocketClientHandshakeException;
import org.apache.commons.lang3.exception.ExceptionUtils;
import org.apache.tinkerpop.gremlin.util.Tokens;
import org.slf4j.Logger;
Expand Down Expand Up @@ -557,7 +558,8 @@ protected void initializeImplementation() {
private void throwNoHostAvailableException() {
final Throwable rootCause = ExceptionUtils.getRootCause(initializationFailure);
// allow the certain exceptions to propagate as a cause
if (rootCause instanceof SSLException || rootCause instanceof ConnectException) {
if (rootCause instanceof SSLException || rootCause instanceof ConnectException ||
rootCause instanceof WebSocketClientHandshakeException) {
throw new NoHostAvailableException(initializationFailure);
} else {
throw new NoHostAvailableException();
Expand Down

0 comments on commit 9bddde4

Please sign in to comment.