Skip to content

HDDS-15138. SCM safemode pipeline rules should honor default EC replication config.#10157

Open
aryangupta1998 wants to merge 1 commit intoapache:masterfrom
aryangupta1998:ec_safemode
Open

HDDS-15138. SCM safemode pipeline rules should honor default EC replication config.#10157
aryangupta1998 wants to merge 1 commit intoapache:masterfrom
aryangupta1998:ec_safemode

Conversation

@aryangupta1998
Copy link
Copy Markdown
Contributor

What changes were proposed in this pull request?

Today SCM safemode pipeline exit checks are effectively hardcoded to RATIS/THREE, which is incorrect when cluster default replication is EC. In EC-default deployments, safemode should validate pipelines for the configured default replication instead of only RATIS/THREE.

This patch generalizes safemode pipeline validation to use ReplicationConfig.getDefault(conf):

HealthyPipelineSafeModeRule now evaluates pipelines matching the configured default replication config and uses required node count from that config.
OneReplicaPipelineSafeModeRule now tracks/report-validates pipelines matching the configured default replication config.
To keep behavior consistent, BackgroundPipelineCreator is updated to include EC pipeline creation when default replication type is EC, while preserving existing RATIS behavior when EC is not configured.

Expected outcome:
RATIS default: behavior remains unchanged.
EC default: safemode pipeline checks validate EC pipelines, and background creation can create EC pipelines accordingly.
Validation
Added/updated below SCM tests for EC-default and RATIS-default paths.

TestHealthyPipelineSafeModeRule
TestOneReplicaPipelineSafeModeRule
TestSCMSafeModeManager
TestBackgroundPipelineCreator

Note:
For EC-default setups in SCM safemode paths, ensure both are set:

ozone.replication.type=EC
ozone.replication=RS-3-2-1024k

What is the link to the Apache JIRA

https://issues.apache.org/jira/browse/HDDS-15138

How was this patch tested?

Unit tests.

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