Hao Hao has posted comments on this change. ( http://gerrit.cloudera.org:8080/10337 )
Change subject: Add a table renaming tool ...................................................................... Patch Set 2: (3 comments) http://gerrit.cloudera.org:8080/#/c/10337/1/src/kudu/tools/kudu-tool-test.cc File src/kudu/tools/kudu-tool-test.cc: http://gerrit.cloudera.org:8080/#/c/10337/1/src/kudu/tools/kudu-tool-test.cc@1847 PS1, Line 1847: : string master_addr = cl > nit: do we need to write any data? Done http://gerrit.cloudera.org:8080/#/c/10337/1/src/kudu/tools/kudu-tool-test.cc@1850 PS1, Line 1850: NO_FATALS(RunActionStdoutNone(Substitute("table rename $0 $1 $2", : master_addr, kTableName, : kNewTableName))); : shared_ptr<KuduClient> client; : ASSERT_OK(KuduClientB > nit: move this down below the tool call, since it's not used until later? Done http://gerrit.cloudera.org:8080/#/c/10337/1/src/kudu/tools/tool_action_table.cc File src/kudu/tools/tool_action_table.cc: http://gerrit.cloudera.org:8080/#/c/10337/1/src/kudu/tools/tool_action_table.cc@121 PS1, Line 121: } : : Status RenameTable(const RunnerContext& context) { : const string& table_name = FindOrDie(context.required_args, kTableNameArg); : const string& new_table_name = FindOrDie(context.required_args, kNewTableNameArg); : : client::sp::shared_ptr<KuduClient> client; : RETURN_NOT_OK(CreateKuduClient(context, &client)); : unique_ptr<KuduTableAlterer> alterer(client->NewTableAlterer(table_name)); : return alterer->RenameTo(new_table_ > seems this is the same code as lines 108-116 above. Can we factor it out so Done -- To view, visit http://gerrit.cloudera.org:8080/10337 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: I49a8c352ded124eef99f341ab552961fc3dc1260 Gerrit-Change-Number: 10337 Gerrit-PatchSet: 2 Gerrit-Owner: Hao Hao <[email protected]> Gerrit-Reviewer: Dan Burkert <[email protected]> Gerrit-Reviewer: Hao Hao <[email protected]> Gerrit-Reviewer: Kudu Jenkins Gerrit-Reviewer: Todd Lipcon <[email protected]> Gerrit-Comment-Date: Tue, 08 May 2018 21:44:57 +0000 Gerrit-HasComments: Yes
