Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Backport 2.6][#9270][backup] Fixed compatibility issue in yb_backup.
Summary: `yb_backup` script must correctly parse output of `yb-admin list_snapshots show_details` command for older releases. Old format: ``` {"type":"NAMESPACE","id":"e4c5591446db417f83a52c679de03118","data":{"name":"a",...}} {"type":"TABLE","id":"d9603c2cab0b48ec807936496ac0e70e","data":{"name":"t2",...,"namespace_id"=...}}}} {"type":"NAMESPACE","id":"e4c5591446db417f83a52c679de03118","data":{"name":"a",...}} {"type":"TABLE","id":"28b5cebe9b0c4cdaa70ce9ceab31b1e5","data":{\ "name":"t2idx","indexed_table_id":"d9603c2cab0b48ec807936496ac0e70e",...,"namespace_id"=...}}}} ``` Plus the old format (before Aug 2020) does not have 'namespace_name' field, which was added later. New format: ``` {"type":"NAMESPACE","id":"e4c5591446db417f83a52c679de03118","data":{"name":"a",...}} {"type":"TABLE","id":"d9603c2cab0b48ec807936496ac0e70e","data":{"name":"t2",...,"namespace_id"=...}} {"type":"TABLE","id":"28b5cebe9b0c4cdaa70ce9ceab31b1e5","data":{\ "name":"t2idx","indexed_table_id":"d9603c2cab0b48ec807936496ac0e70e",...,"namespace_id"=...}}}} ``` Original diff: https://phabricator.dev.yugabyte.com/D11420 Original commit: e8c72f3 Test Plan: Jenkins: rebase: 2.6, hot Existing backup tests: ybd --cxx-test tools_yb-backup-test_ent ybd --java-test org.yb.pgsql.TestYbBackup ybd --java-test org.yb.cql.TestYbBackup --tp 1 Reviewers: bogdan, sergei Reviewed By: sergei Subscribers: jenkins-bot, yql Differential Revision: https://phabricator.dev.yugabyte.com/D12873
- Loading branch information