Skip to content

Aggregate goroutine leak when exceed quota #58004

@wshwsh12

Description

@wshwsh12

Bug Report

Please answer these questions before submitting your issue. Thanks!

1. Minimal reproduce step (Required)

Sql file 1.txt

use test;
source 1.txt;

2. What did you expect to see? (Required)

No leak

3. What did you see instead (Required)

goroutine 6322 [select, 2 minutes]:
github.com/pingcap/tidb/pkg/executor.readProjection[...](...)
	/home/wshwsh12/project/tidb/pkg/executor/projection.go:492
github.com/pingcap/tidb/pkg/executor.(*projectionWorker).run(0xc019d52e40, {0x70c2808?, 0xc019d211a0?})
	/home/wshwsh12/project/tidb/pkg/executor/projection.go:460 +0x167
created by github.com/pingcap/tidb/pkg/executor.(*ProjectionExec).prepare in goroutine 6305
	/home/wshwsh12/project/tidb/pkg/executor/projection.go:303 +0x6c6

goroutine 6001 [select, 2 minutes]:
github.com/pingcap/tidb/pkg/store/copr.(*copIteratorWorker).sendToRespCh(0xc019a38230?, 0xc018ed9ef0?, 0xc0190cf730?, 0x80?)
	/home/wshwsh12/project/tidb/pkg/store/copr/coprocessor.go:1025 +0xa6
github.com/pingcap/tidb/pkg/store/copr.(*copIteratorWorker).handleCopResponse(0xc019a38230, 0xc01799df48, 0xc018edf480, 0xc018ed9ef0, {0xc018e84d80, 0x89, 0x89}, 0x0, 0xc019a28380, 0xc0190cf730, ...)
	/home/wshwsh12/project/tidb/pkg/store/copr/coprocessor.go:1496 +0x77a
github.com/pingcap/tidb/pkg/store/copr.(*copIteratorWorker).handleCopPagingResult(0xc019a38230, 0x0?, 0x0?, 0xc018ed9ef0, {0xc018e84d80?, 0xc018ef56c0?, 0x0?}, 0x0?, 0xc019a28380, 0xc0190cf730, ...)
	/home/wshwsh12/project/tidb/pkg/store/copr/coprocessor.go:1392 +0x59
github.com/pingcap/tidb/pkg/store/copr.(*copIteratorWorker).handleTaskOnce(0xc019a38230, 0xc01799df48, 0xc019a28380, 0xc0190cf730)
	/home/wshwsh12/project/tidb/pkg/store/copr/coprocessor.go:1319 +0xfcc
github.com/pingcap/tidb/pkg/store/copr.(*copIteratorWorker).handleTask(0xc019a38230, {0x70c2808, 0xc019a2d710}, 0x0?, 0xc0190cf730)
	/home/wshwsh12/project/tidb/pkg/store/copr/coprocessor.go:1169 +0x16e
github.com/pingcap/tidb/pkg/store/copr.(*copIteratorWorker).run(0xc019a38230, {0x70c2808, 0xc019a2d710})
	/home/wshwsh12/project/tidb/pkg/store/copr/coprocessor.go:836 +0x111
created by github.com/pingcap/tidb/pkg/store/copr.(*copIterator).open in goroutine 3266
	/home/wshwsh12/project/tidb/pkg/store/copr/coprocessor.go:884 +0x105

4. What is your TiDB version? (Required)

master

Metadata

Metadata

Labels

affects-6.5This bug affects the 6.5.x(LTS) versions.affects-7.1This bug affects the 7.1.x(LTS) versions.affects-7.5This bug affects the 7.5.x(LTS) versions.affects-8.1This bug affects the 8.1.x(LTS) versions.affects-8.5This bug affects the 8.5.x(LTS) versions.impact/leakseverity/majorsig/executionSIG executiontype/bugThe issue is confirmed as a bug.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions