Skip to content

Commit

Permalink
executor: make channel buffer small in sort executor (#53881)
Browse files Browse the repository at this point in the history
close #53866
  • Loading branch information
xzhangxian1008 authored Jun 11, 2024
1 parent 7a18952 commit fedf3b7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/executor/sortexec/sort.go
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ func (e *SortExec) Open(ctx context.Context) error {
e.Parallel.chunkChannel = make(chan *chunkWithMemoryUsage, e.Ctx().GetSessionVars().ExecutorConcurrency)
e.Parallel.fetcherAndWorkerSyncer = &sync.WaitGroup{}
e.Parallel.sortedRowsIters = make([]*chunk.Iterator4Slice, len(e.Parallel.workers))
e.Parallel.resultChannel = make(chan rowWithError, e.MaxChunkSize())
e.Parallel.resultChannel = make(chan rowWithError, 10)
e.Parallel.closeSync = make(chan struct{})
e.Parallel.merger = newMultiWayMerger(&memorySource{sortedRowsIters: e.Parallel.sortedRowsIters}, e.lessRow)
e.Parallel.spillHelper = newParallelSortSpillHelper(e, exec.RetTypes(e), e.finishCh, e.lessRow, e.Parallel.resultChannel)
Expand Down

0 comments on commit fedf3b7

Please sign in to comment.