Skip to content

HBASE-30385 Fix duplicate system region move scheduling - #8658

Open
Huginn-kio wants to merge 1 commit into
apache:masterfrom
Huginn-kio:HBASE-30385
Open

Huginn-kio wants to merge 1 commit into
apache:masterfrom
Huginn-kio:HBASE-30385

Conversation

@Huginn-kio

@Huginn-kio Huginn-kio commented Sep 16, 2026

Copy link
Copy Markdown
Contributor

HBASE-30385

Summary

AssignmentManager.checkIfShouldMoveSystemRegionAsync() can schedule the same
system-region move more than once when multiple excluded RegionServers are
processed. This can cause a subsequent move submission to fail because the
region is already in transition. See HBASE-30385.

Root cause

On Apache master, plans is collected before the loop over excluded servers,
but the loop that submits the collected plans is inside that outer loop
(hbase-server/src/main/java/org/apache/hadoop/hbase/master/assignment/AssignmentManager.java,
around lines 741-745). Plans collected from an earlier server are therefore
submitted again for each later excluded server. The log also reports the outer
loop variable instead of the plan source.

Fix

  • Submit the collected RegionPlans after processing all excluded servers.
  • Log plan.getSource() so the reported source matches the plan being moved.

Testing

  • Failing-before-fix evidence: The duplicate scheduling is demonstrated by
    the existing control flow and the reported in-transition exception; no
    standalone regression test was added.
  • Passing-after-fix evidence: git diff --check passed.
  • Neighbor regression slice: Not run; no unit test was added for this
    small control-flow correction.
  • Static analysis: Targeted checkstyle completed with no violations on the
    modified lines. The full file still reports three pre-existing violations
    outside this diff.

Compatibility

  • Public API impact: none
  • Config impact: none
  • Persisted format impact: none
  • Wire format impact: none

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant