Skip to content

labelLevelStats may leak when merging regions #8700

@rleungx

Description

@rleungx

Bug Report

Consider the following case:

  1. Patrol region has scanned a batch of regions, e.g., a,b,c,d
  2. Before updating label statistics, the merge finished, e.g., merge a and b
  3. PD will remove one of the regions, assumed b, from label statistics because of overlaps during the process of region heartbeat.
  4. Then patrol region update a,b,c,d to label statistics

b will never be deleted again and left in memory until the PD is restarted.

Metadata

Metadata

Assignees

No one assigned

    Labels

    affects-5.4This bug affects the 5.4.x(LTS) versions.affects-6.1This bug affects the 6.1.x(LTS) versions.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.4severity/majortype/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