Skip to content

Commit a9a48e2

Browse files
test commit
1 parent e6472dd commit a9a48e2

File tree

3 files changed

+5
-1
lines changed

3 files changed

+5
-1
lines changed

src/EFCore.Ydb/src/Storage/Internal/YdbExecutionStrategy.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,5 @@ public class YdbExecutionStrategy(ExecutionStrategyDependencies dependencies)
88
: ExecutionStrategy(dependencies, maxRetryCount: 10, maxRetryDelay: TimeSpan.FromSeconds(10)) // TODO User settings
99
{
1010
protected override bool ShouldRetryOn(Exception exception)
11-
=> exception is YdbException { IsTransient: true };
11+
=> exception is YdbException { IsTransientWhenIdempotent: true };
1212
}

src/EFCore.Ydb/src/Storage/Internal/YdbTypeMappingSource.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ RelationalTypeMappingSourceDependencies relationalDependencies
6767
{ "Double", [Double] },
6868

6969
{ "Decimal", [Decimal] },
70+
7071
{ "Guid", [Guid] },
7172

7273
{ "Date", [Date] },

src/Ydb.Sdk/src/Ado/YdbConnection.cs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,12 +92,15 @@ public override async Task OpenAsync(CancellationToken cancellationToken)
9292
{
9393
ThrowIfConnectionOpen();
9494

95+
ConnectionState = ConnectionState.Connecting;
9596
try
9697
{
9798
Session = await PoolManager.GetSession(ConnectionStringBuilder, cancellationToken);
9899
}
99100
catch (Exception e)
100101
{
102+
ConnectionState = ConnectionState.Closed;
103+
101104
throw e switch
102105
{
103106
OperationCanceledException => throw new YdbException(StatusCode.Cancelled,

0 commit comments

Comments
 (0)