Skip to content

Commit 9263030

Browse files
author
Zhen
committed
Fix window build due to different error type when failing to read from buffer
1 parent 4d094ce commit 9263030

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

driver/src/main/java/org/neo4j/driver/internal/net/BufferingChunkedInput.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -427,7 +427,7 @@ private static void readNextPacket( ReadableByteChannel channel, ByteBuffer buff
427427
catch ( IOException e )
428428
{
429429
String message = e.getMessage() == null ? e.getClass().getSimpleName() : e.getMessage();
430-
throw new ClientException(
430+
throw new ConnectionFailureException(
431431
"Unable to process request: " + message + " buffer: \n" + BytePrinter.hex( buffer ), e );
432432
}
433433
}

driver/src/main/java/org/neo4j/driver/v1/exceptions/ConnectionFailureException.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,9 @@ public ConnectionFailureException( String message )
2929
{
3030
super( message );
3131
}
32+
33+
public ConnectionFailureException( String message, Throwable e )
34+
{
35+
super( message, e );
36+
}
3237
}

0 commit comments

Comments
 (0)