-
Notifications
You must be signed in to change notification settings - Fork 147
1.2 changelog
- Remember seed URI and perform DNS-lookup for it during rediscovery #220
- Fix streaming of queued records in
StreamObserver
#222 - Avoid retrying transactions that were explicitly terminated by the user #223
-
Fixed JSDoc for
Node
,Relationship
andPathSegment
classes #210 -
Fixed purging of network connections after rediscovery #212
-
Decoupled network connection from the
Session
. Previously session was bound to a connection and used same connection throughout its lifetime. Now new connection will be used for eachSession#run()
and each transaction started withSession#beginTransaction()
. This improves load-balancing and makes idle connections return to the pool as soon as possible #215 -
Allowed initial bookmark in session. Added second parameter
bookmark
to the existingDriver#session(accessMode)
API function to allow creation of a session with the specified initial bookmark. This means that first transaction in the created session will ensure that the server, it is connected to, is at least up to the database version denoted by the bookmark. Bookmark is a session related concept and this commit adds symmetry with regards toSession#lastBookmark()
function #216 -
Added transaction with retries API. This change introduces two new API functions:
Session#readTransaction()
Session#writeTransaction()
Both take a single function as input. This function takes a single argument of type
Transaction
and returns a promise. It can be used to perform regular async operations like query execution. Introduced functions will commit/rollback transaction depending on the returned promise, so user code does not need to callTransaction#commit()
explicitly. They also perform retries if given transaction fails with network errors (ServiceUnavaliable
orSessionExpired
) or with transient errors (DeadlockDetected
, etc.). Retries are performed with exponential backoff with initial delay of 1 second and maximum retry time of 30 seconds. Maximum transaction retry time is configurable viamaxTransactionRetryTime
property of the driver configuration. These API functions are useful to hide tolerable network problems and transient errors for both single and causal cluster deployments. #219