Hao Hao has posted comments on this change.

Change subject: KUDU-1898: /varz page doesn't HTML-escape flag values
......................................................................


Patch Set 1:

(4 comments)

http://gerrit.cloudera.org:8080/#/c/6173/1/src/kudu/util/flag_tags-test.cc
File src/kudu/util/flag_tags-test.cc:

Line 120: TEST_F(FlagTagsTest, TestSensitiveFlags) {
> Maybe we can augment this to also call CommandLineFlagsIntoString(true) and
My bad, WebserverTest.TestRedactFlagsDump is testing html-escaped value.


http://gerrit.cloudera.org:8080/#/c/6173/1/src/kudu/util/flags.cc
File src/kudu/util/flags.cc:

PS1, Line 420: // Redact the flag tagged as 'sensitive', if --redact is set
             : // with 'flag'. Otherwise, return its value as-is. If 
should_escape_html
             : // is true, return html escaped string.
> Nit: we don't typically write function-level comments like these in the .cc
But CheckFlagAndRedact is not a "public" function, it is only used inside 
flags.cc. Am I missing something?


Line 424:   string ret_value;
> FWIW, 'retval' is a fine variable name (you can grep for it and see it used
Got it, thanks!


http://gerrit.cloudera.org:8080/#/c/6173/1/src/kudu/util/flags.h
File src/kudu/util/flags.h:

Line 56: std::string CommandlineFlagsIntoString(bool should_escape_html);
> Nit: the problem with boolean command line arguments is that it's tough to 
Done


-- 
To view, visit http://gerrit.cloudera.org:8080/6173
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I64ebb0befe6bacb0fc90d50a1e34870656041a01
Gerrit-PatchSet: 1
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Hao Hao <[email protected]>
Gerrit-Reviewer: Adar Dembo <[email protected]>
Gerrit-Reviewer: Hao Hao <[email protected]>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-HasComments: Yes

Reply via email to