Hao Hao has posted comments on this change. ( http://gerrit.cloudera.org:8080/15416 )
Change subject: [ranger] pass 'principal' and 'keytab' to the subprocess ...................................................................... Patch Set 6: (1 comment) http://gerrit.cloudera.org:8080/#/c/15416/4/src/kudu/ranger/ranger_client.cc File src/kudu/ranger/ranger_client.cc: http://gerrit.cloudera.org:8080/#/c/15416/4/src/kudu/ranger/ranger_client.cc@191 PS4, Line 191: Status BuildArgv(vector<string>* argv) { : DCHECK(argv); : // Pass the required arguments to run the Ranger subprocess. : vector<string> ret = { FLAGS_ranger_java_path, "-cp", GetJavaClasspath(), kMainClass }; : // When Kerberos is enabled in Kudu, pass both Kudu principal and keytab file : // to the Ranger subprocess. : if (!FLAGS_keytab_file.empty()) { : string configured_principal; : RETURN_NOT_OK_PREPEND(security::GetConfiguredPrincipal(FLAGS_principal, &configured_principal), : Substitute("unable to get the configured principal from ($0) for " : "the Ranger subprocess", FLAGS_principal)); : argv->emplace_back("-i"); : argv->emplace_back(configured_principal); : argv->emplace_back("-k"); : argv->emplace_back(FLAGS_keytab_file); : }; : : *argv = std::move(ret); : return Status::OK(); : } > nit: this would be cleaner as: Done -- To view, visit http://gerrit.cloudera.org:8080/15416 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: Ie30b835b6d44ddb51d95c587f1329bfefebeb37c Gerrit-Change-Number: 15416 Gerrit-PatchSet: 6 Gerrit-Owner: Hao Hao <[email protected]> Gerrit-Reviewer: Adar Dembo <[email protected]> Gerrit-Reviewer: Andrew Wong <[email protected]> Gerrit-Reviewer: Attila Bukor <[email protected]> Gerrit-Reviewer: Hao Hao <[email protected]> Gerrit-Reviewer: Kudu Jenkins (120) Gerrit-Comment-Date: Sun, 15 Mar 2020 04:44:34 +0000 Gerrit-HasComments: Yes
