Will Berkeley has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/12038 )

Change subject: [tools] ksck output could be filtered by sections
......................................................................


Patch Set 1:

(13 comments)

Thanks for posting this! It looks good. It needs a couple of tests verifying 
that it includes and excludes the right sections when the flag is non-default, 
both for plain and JSON output.

http://gerrit.cloudera.org:8080/#/c/12038/1//COMMIT_MSG
Commit Message:

http://gerrit.cloudera.org:8080/#/c/12038/1//COMMIT_MSG@10
PS1, Line 10: which
and


http://gerrit.cloudera.org:8080/#/c/12038/1//COMMIT_MSG@10
PS1, Line 10: ,
.


http://gerrit.cloudera.org:8080/#/c/12038/1//COMMIT_MSG@10
PS1, Line 10: could
can


http://gerrit.cloudera.org:8080/#/c/12038/1//COMMIT_MSG@11
PS1, Line 11: add
adds


http://gerrit.cloudera.org:8080/#/c/12038/1//COMMIT_MSG@11
PS1, Line 11: this
This


http://gerrit.cloudera.org:8080/#/c/12038/1//COMMIT_MSG@11
PS1, Line 11: filte
filter


http://gerrit.cloudera.org:8080/#/c/12038/1/src/kudu/tools/ksck-test.cc
File src/kudu/tools/ksck-test.cc:

http://gerrit.cloudera.org:8080/#/c/12038/1/src/kudu/tools/ksck-test.cc@409
PS1, Line 409: , json_stream
Put this on its own line so all of the arguments are on separate lines.


http://gerrit.cloudera.org:8080/#/c/12038/1/src/kudu/tools/ksck.h
File src/kudu/tools/ksck.h:

http://gerrit.cloudera.org:8080/#/c/12038/1/src/kudu/tools/ksck.h@580
PS1, Line 580: print_sections_
Let's call it 'print_sections_flags_'.


http://gerrit.cloudera.org:8080/#/c/12038/1/src/kudu/tools/ksck_results.h
File src/kudu/tools/ksck_results.h:

http://gerrit.cloudera.org:8080/#/c/12038/1/src/kudu/tools/ksck_results.h@273
PS1, Line 273: print all sections above
Print all sections above.


http://gerrit.cloudera.org:8080/#/c/12038/1/src/kudu/tools/ksck_results.h@274
PS1, Line 274: DEFAULT_PRINT_SECTIONS
Let's call it ALL_SECTIONS so it's obvious in context that it means everything.


http://gerrit.cloudera.org:8080/#/c/12038/1/src/kudu/tools/ksck_results.h@324
PS1, Line 324:  and sections 'sections'
nit: I'd state the purpose of this as a separate sentence, e.g.

Print this KsckResults to 'out' according to the PrintMode 'mode'. The sections 
printed will be limited according to the value of 'sections'.


http://gerrit.cloudera.org:8080/#/c/12038/1/src/kudu/tools/ksck_results.h@327
PS1, Line 327: and printed sections are limited by 'sections'.
nit: Here too.


http://gerrit.cloudera.org:8080/#/c/12038/1/src/kudu/tools/tool_action_cluster.cc
File src/kudu/tools/tool_action_cluster.cc:

http://gerrit.cloudera.org:8080/#/c/12038/1/src/kudu/tools/tool_action_cluster.cc@71
PS1, Line 71: "MASTER_SUMMARIES,TSERVER_SUMMARIES,VERSION_SUMMARIES,"
            :                         
"TABLET_SUMMARIES,TABLE_SUMMARIES,CHECKSUM_RESULTS,TOTAL_COUNT"
To ease adding new sections, given that the default should be to print 
everything, I think we should have a special "ALL_SECTIONS" or "*" value that 
means print everything, and that should be the default.



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

Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ic31dcb7795b5c510b40fa2024960306b9da40e05
Gerrit-Change-Number: 12038
Gerrit-PatchSet: 1
Gerrit-Owner: Yingchun Lai <[email protected]>
Gerrit-Reviewer: Adar Dembo <[email protected]>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Will Berkeley <[email protected]>
Gerrit-Comment-Date: Thu, 06 Dec 2018 19:04:31 +0000
Gerrit-HasComments: Yes

Reply via email to