Skip to content

Issue 4735: Preserve dead bookies when stabilize slave is active - #4889

Open
arimu1 wants to merge 1 commit into
apache:masterfrom
arimu1:fix/4735-on-cluster-changed-dead-bookies
Open

arimu1 wants to merge 1 commit into
apache:masterfrom
arimu1:fix/4735-on-cluster-changed-dead-bookies

Conversation

@arimu1

@arimu1 arimu1 commented Sep 12, 2026

Copy link
Copy Markdown

Fixes #4735

Motivation

RackawareEnsemblePlacementPolicy.onClusterChanged forwards cluster updates to a slave policy when networkTopologyStabilizePeriodSeconds > 0. The implementation replaced the parent dead-bookie set with the slave return value, so a bookie removal could yield an empty set even though the parent (non-stabilized) policy had already detected the departure.

Changes

  • Union the parent and slave dead-bookie sets in onClusterChanged instead of assigning over the parent result.
  • Update testPlacementOnStabilizeNetworkTopology to assert the removed bookie is reported as dead when stabilization is enabled.

Test plan

  • JAVA_HOME=…/jdk-21 mvn -pl bookkeeper-server -Dtest=TestRackawareEnsemblePlacementPolicy#testPlacementOnStabilizeNetworkTopology test

When network topology stabilization uses a slave policy, onClusterChanged
must not replace the parent dead-bookie set with the slave result.
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.

Bug onClusterChange() for bookie deletion

1 participant