Skip to content

Commit 19eb042

Browse files
Peter Wilhelmsson2hdddg
authored andcommitted
Fix problem with failed retriable transactions in cluster
During rolling upgrades of clusters the handshake can be interrupted and a read during handshake can fail, this should be retried. Change the exception raised for this condition.
1 parent bea0784 commit 19eb042

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

neo4j/io/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1006,7 +1006,7 @@ def _handshake(s, resolved_address):
10061006
# response, the server has closed the connection
10071007
log.debug("[#%04X] S: <CLOSE>", local_port)
10081008
s.close()
1009-
raise BoltHandshakeError("Connection to {address} closed without handshake response".format(address=resolved_address), address=resolved_address, request_data=handshake, response_data=None)
1009+
raise ServiceUnavailable("Connection to {address} closed without handshake response".format(address=resolved_address))
10101010
if data_size != 4:
10111011
# Some garbled data has been received
10121012
log.debug("[#%04X] S: @*#!", local_port)

0 commit comments

Comments
 (0)