Skip to content

Commit 5a201cf

Browse files
committed
tech(tsdb): abort batch procces when context closes
1 parent d889415 commit 5a201cf

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

pkg/tsdb/request.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,8 @@ func HandleRequest(ctx context.Context, req *Request) (*Response, error) {
5151
go batch.process(ctx, context)
5252
}
5353
}
54+
case <-ctx.Done():
55+
return nil, ctx.Err()
5456
}
5557
}
5658

0 commit comments

Comments
 (0)