Skip to content

disk-based partialResultMap for HashAggExec #14413

@XuHuaiyu

Description

@XuHuaiyu

Feature Request

Is your feature request related to a problem? Please describe:

The main memory space consumption of HashAggExec is HashAggExec.partialResultMap which is of type aggPartialResultMapper.
https://github.com/pingcap/tidb/blob/master/executor/aggregate.go#L41

To avoid OOM in HashAggExec, we need a disk-based aggPartialResultMapper.

Describe the feature you'd like:

Implement a disk-based aggPartialResultMapper, partialResultMap should be spilled over to disk when mem-quota-query in tidb.toml is exceeded.

Describe alternatives you've considered:

Teachability, Documentation, Adoption, Migration Strategy:

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions