Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.Map;
import java.util.Objects;
import java.util.Optional;
import java.util.concurrent.TimeUnit;
import java.util.concurrent.TimeoutException;
Expand Down Expand Up @@ -181,6 +182,10 @@ else if (e instanceof SocketException) {
// All known SocketException are retryable.
return new TDClientSocketException(socketException);
}
else if (Objects.equals(socketException.getMessage(), "Socket closed")) {
// okhttp can raise java.net.SocketException("Socket closed")
return new TDClientSocketException(socketException);
}
else {
// Other unknown SocketException are considered non-retryable.
throw new TDClientSocketException(socketException);
Expand Down
Loading