Skip to content

Commit b08ebd5

Browse files
committed
change ct in Flush
1 parent beec0e0 commit b08ebd5

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

src/Ydb.Sdk/src/Ado/BulkUpsert/BulkUpsertImporter.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ public async ValueTask AddRowAsync(object?[] values)
4848

4949
if (_currentBytes + rowSize > _maxBytes && _rows.Count > 0)
5050
{
51-
await FlushAsync(_cancellationToken);
51+
await FlushAsync();
5252
}
5353

5454
_rows.Add(protoStruct);
@@ -67,7 +67,7 @@ public async ValueTask AddRowAsync(object?[] values)
6767
};
6868
}
6969

70-
public async ValueTask FlushAsync(CancellationToken cancellationToken = default)
70+
public async ValueTask FlushAsync()
7171
{
7272
if (_rows.Count == 0) return;
7373
if (_structType == null)
@@ -84,7 +84,7 @@ public async ValueTask FlushAsync(CancellationToken cancellationToken = default)
8484
var resp = await _driver.UnaryCall(
8585
TableService.BulkUpsertMethod,
8686
req,
87-
new GrpcRequestSettings { CancellationToken = cancellationToken }
87+
new GrpcRequestSettings { CancellationToken = _cancellationToken }
8888
).ConfigureAwait(false);
8989

9090
var operation = resp.Operation;

src/Ydb.Sdk/src/Ado/BulkUpsert/IBulkUpsertImporter.cs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ namespace Ydb.Sdk.Ado.BulkUpsert;
22

33
public interface IBulkUpsertImporter
44
{
5-
ValueTask AddRowAsync(object?[] rows);
6-
ValueTask FlushAsync(CancellationToken cancellationToken = default);
5+
ValueTask AddRowAsync(object?[] row);
6+
7+
ValueTask FlushAsync();
78
}

0 commit comments

Comments
 (0)