Skip to content

Commit 67facd9

Browse files
authored
fix(bigquery/storage/managedwriter): fix flowcontroller double-release (#4555)
Stress testing caught this one: responsibility for releasing flow controlled resources is in markDone of pending write, and the reference in the recvProcessor was over-freeing resources. Towards: #4366
1 parent 1606a69 commit 67facd9

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

Diff for: bigquery/storage/managedwriter/managed_stream.go

-1
Original file line numberDiff line numberDiff line change
@@ -358,7 +358,6 @@ func recvProcessor(ctx context.Context, arc storagepb.BigQueryWrite_AppendRowsCl
358358
recordStat(ctx, AppendResponses, 1)
359359

360360
if status := resp.GetError(); status != nil {
361-
fc.release(nextWrite.reqSize)
362361
nextWrite.markDone(NoStreamOffset, grpcstatus.ErrorProto(status), fc)
363362
continue
364363
}

0 commit comments

Comments
 (0)