[kudu-CR] Fix tests leaving behind diagnostics logs
Todd Lipcon has submitted this change and it was merged. ( http://gerrit.cloudera.org:8080/9592 ) Change subject: Fix tests leaving behind diagnostics logs .. Fix tests leaving behind diagnostics logs Prior to this patch, if tests are run with TEST_TMPDIR set, tests which use an internal minicluster could leave behind a diagnostics log file. The issue was the following: - GLog has some code which defaults FLAGS_log_dir to the the $TEST_TMPDIR environment variable. - Since we enabled the diagnosics log by default, this meant that minicluster servers would start logging into $TEST_TMPDIR directly - Our test harness only takes care of cleaning up the test-case-specific directory rather than the top-level $TEST_TMPDIR The fix here is to make our own test harness override FLAGS_log_dir to point to the test-specific directory. Tested by setting TEST_TMPDIR and running tablet_server-test. Before the patch, it left some files behind. With the patch, it did not. I couldn't write an easy automated test since the initialization of FLAGS_log_dir happens during glog's static constructors. Change-Id: Ic68826f652c7aefce1314d9e3481b11666f2699f Reviewed-on: http://gerrit.cloudera.org:8080/9592 Reviewed-by: Adar Dembo Tested-by: Todd Lipcon --- M src/kudu/master/master-test.cc M src/kudu/util/test_util.cc 2 files changed, 10 insertions(+), 1 deletion(-) Approvals: Adar Dembo: Looks good to me, approved Todd Lipcon: Verified -- To view, visit http://gerrit.cloudera.org:8080/9592 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: merged Gerrit-Change-Id: Ic68826f652c7aefce1314d9e3481b11666f2699f Gerrit-Change-Number: 9592 Gerrit-PatchSet: 2 Gerrit-Owner: Todd Lipcon Gerrit-Reviewer: Adar Dembo Gerrit-Reviewer: Kudu Jenkins Gerrit-Reviewer: Todd Lipcon
[kudu-CR] Fix tests leaving behind diagnostics logs
Todd Lipcon has removed a vote on this change. Change subject: Fix tests leaving behind diagnostics logs .. Removed Verified-1 by Kudu Jenkins (120) -- To view, visit http://gerrit.cloudera.org:8080/9592 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: deleteVote Gerrit-Change-Id: Ic68826f652c7aefce1314d9e3481b11666f2699f Gerrit-Change-Number: 9592 Gerrit-PatchSet: 1 Gerrit-Owner: Todd Lipcon Gerrit-Reviewer: Adar Dembo Gerrit-Reviewer: Kudu Jenkins
[kudu-CR] Fix tests leaving behind diagnostics logs
Todd Lipcon has posted comments on this change. ( http://gerrit.cloudera.org:8080/9592 ) Change subject: Fix tests leaving behind diagnostics logs .. Patch Set 1: Verified+1 Unrelated tablet_copy flake -- To view, visit http://gerrit.cloudera.org:8080/9592 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: Ic68826f652c7aefce1314d9e3481b11666f2699f Gerrit-Change-Number: 9592 Gerrit-PatchSet: 1 Gerrit-Owner: Todd Lipcon Gerrit-Reviewer: Adar Dembo Gerrit-Reviewer: Kudu Jenkins Gerrit-Reviewer: Todd Lipcon Gerrit-Comment-Date: Mon, 12 Mar 2018 23:28:10 + Gerrit-HasComments: No
[kudu-CR] Fix tests leaving behind diagnostics logs
Adar Dembo has posted comments on this change. ( http://gerrit.cloudera.org:8080/9592 ) Change subject: Fix tests leaving behind diagnostics logs .. Patch Set 1: Code-Review+2 -- To view, visit http://gerrit.cloudera.org:8080/9592 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: Ic68826f652c7aefce1314d9e3481b11666f2699f Gerrit-Change-Number: 9592 Gerrit-PatchSet: 1 Gerrit-Owner: Todd Lipcon Gerrit-Reviewer: Adar Dembo Gerrit-Reviewer: Kudu Jenkins Gerrit-Comment-Date: Mon, 12 Mar 2018 23:03:51 + Gerrit-HasComments: No
[kudu-CR] Fix tests leaving behind diagnostics logs
Hello Adar Dembo, I'd like you to do a code review. Please visit http://gerrit.cloudera.org:8080/9592 to review the following change. Change subject: Fix tests leaving behind diagnostics logs .. Fix tests leaving behind diagnostics logs Prior to this patch, if tests are run with TEST_TMPDIR set, tests which use an internal minicluster could leave behind a diagnostics log file. The issue was the following: - GLog has some code which defaults FLAGS_log_dir to the the $TEST_TMPDIR environment variable. - Since we enabled the diagnosics log by default, this meant that minicluster servers would start logging into $TEST_TMPDIR directly - Our test harness only takes care of cleaning up the test-case-specific directory rather than the top-level $TEST_TMPDIR The fix here is to make our own test harness override FLAGS_log_dir to point to the test-specific directory. Tested by setting TEST_TMPDIR and running tablet_server-test. Before the patch, it left some files behind. With the patch, it did not. I couldn't write an easy automated test since the initialization of FLAGS_log_dir happens during glog's static constructors. Change-Id: Ic68826f652c7aefce1314d9e3481b11666f2699f --- M src/kudu/master/master-test.cc M src/kudu/util/test_util.cc 2 files changed, 10 insertions(+), 1 deletion(-) git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/92/9592/1 -- To view, visit http://gerrit.cloudera.org:8080/9592 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: newchange Gerrit-Change-Id: Ic68826f652c7aefce1314d9e3481b11666f2699f Gerrit-Change-Number: 9592 Gerrit-PatchSet: 1 Gerrit-Owner: Todd Lipcon Gerrit-Reviewer: Adar Dembo