ydb-platform / ydb-java-sdk

YDB Java SDK
https://ydb.tech
Apache License 2.0
36 stars 20 forks source link

Add support of transactions to SessionRetryContext #27

Open alex268 opened 1 year ago

alex268 commented 1 year ago

It is necessary to modify the SessionRetryContext class to work correctly with transactions, considering autocommit and interactive modes

eivanov89 commented 1 year ago

Also there is an issue with backoff algorithm in backoffTimeMillisInternal(). Because of return backoffSlotMillis + ThreadLocalRandom.current().nextLong(maxDurationMillis) it is possible that each next delay is smaller, than previous one.