[BOOKIE-SHELL] Add cmd to change bookie-address into ledger metadata
authorRajan Dhabalia <rdhabalia@apache.org>
Thu, 18 Jun 2020 07:04:18 +0000 (00:04 -0700)
committerGitHub <noreply@github.com>
Thu, 18 Jun 2020 07:04:18 +0000 (09:04 +0200)
commit2650985413081580bc93c0cc88f8c9369238890e
tree264e4720b188bad27e9fb0347e45f112f273a91e
parentb411dac67db385b033db875f5926465201ec3471
[BOOKIE-SHELL] Add cmd to change bookie-address into ledger metadata

### Motivation
In a large bookie cluster environment, we frequently require a utility to change bookie-ip with a different bookie-ip in ledger's metadata in different scenarios such as:
1. Host Re-IP: requires updating ledger metadata and reuse the host without losing/copying data
2. Backup-restore usecase while doing cluster level data migration.
Therefore, we frequently need a tool to update bookie-ip with a new bookie-ip in existing ledgers' ensemble metadata.

### Modification
Add CLI command to update bookie-id in ledger metadata.

Reviewers: Enrico Olivelli <eolivelli@gmail.com>, Sijie Guo <None>, Jia Zhai <zhaijia@apache.org>

This closes #2321 from rdhabalia/reip
bookkeeper-server/src/main/java/org/apache/bookkeeper/bookie/BookieShell.java
bookkeeper-server/src/main/java/org/apache/bookkeeper/tools/cli/commands/bookie/UpdateBookieInLedgerCommand.java [new file with mode: 0644]
bookkeeper-server/src/test/java/org/apache/bookkeeper/client/UpdateLedgerCmdTest.java
site/_data/cli/shell.yaml