hani-fouladgar opened a new pull request, #10495:
URL: https://github.com/apache/ozone/pull/10495
## What changes were proposed in this pull request?
### Summary
This PR standardizes Ozone CLI long option names to kebab-case
(`--max-size-to-move-per-iteration-in-gb`) and deprecates legacy camelCase
(`--maxSizeToMovePerIterationInGB`) and underscore (`--column_family`) variants.
### Core infrastructure
- Adds `DeprecatedCliOptions` in `hadoop-hdds/cli-common` with shared
helpers to:
- Detect which option was actually passed on the command line
- Resolve canonical vs deprecated values
- Print stderr warnings like: `warning: --maxSizeToMovePerIterationInGB is
deprecated, use --max-size-to-move-per-iteration-in-gb instead.`
- Deprecated aliases are kept as hidden `@Option` fields for backward
compatibility; canonical kebab-case options are shown in help.
### CLI commands updated
- Admin / SCM: container balancer start, pipeline create/list/filter, OM/SCM
leader transfer
- Debug: `ozone debug ldb` (scan/value schema), Ratis log parser,
container-to-key mapping
- Repair: RocksDB manual compaction, OM DB compact
- Shell: put key, set S3 secret, tenant assign user access ID
- Freon / benchmarks: `randomkeys`, Hadoop dir generators, SCM throughput
benchmark
### Documentation
- Updates CLI docs to show only kebab-case options (Container Balancer,
OM/SCM HA, Repair, Ldb, Ratis log parser, Freon examples).
### Backward compatibility
- Existing scripts using camelCase or underscore long options continue to
work.
- Users are warned to migrate to kebab-case; no behavior change when using
canonical options.
## What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-7956
## How was this patch tested?
- Adds unit tests in `TestContainerBalancerSubCommand` verifying:
- Deprecated flags still work but emit warnings
- Deprecated flags are hidden from help output
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]