Skip to content

Commit

Permalink
colflow: fix a recent flake
Browse files Browse the repository at this point in the history
In 0866ddc we merged a change that
relied on the assumption that the allocator passed to the parallel
unordered synchronizer was not used by anyone else, but this assumption
was broken in a test and is now fixed.

Release note: None
  • Loading branch information
yuzefovich committed Aug 1, 2022
1 parent 590049f commit 1d20a8c
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion pkg/sql/colflow/vectorized_flow_shutdown_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,13 @@ func TestVectorizedFlowShutdown(t *testing.T) {
},
)
}
synchronizer := colexec.NewParallelUnorderedSynchronizer(testAllocator, synchronizerInputs, &wg)
syncMemAccount := testMemMonitor.MakeBoundAccount()
defer syncMemAccount.Close(ctx)
// Note that here - for the purposes of the test - it doesn't
// matter which context we use since it'll only be used by the
// memory accounting system.
syncAllocator := colmem.NewAllocator(ctx, &syncMemAccount, testColumnFactory)
synchronizer := colexec.NewParallelUnorderedSynchronizer(syncAllocator, synchronizerInputs, &wg)
inputMetadataSource := colexecop.MetadataSource(synchronizer)
flowID := execinfrapb.FlowID{UUID: uuid.MakeV4()}

Expand Down

0 comments on commit 1d20a8c

Please sign in to comment.