aboutsummaryrefslogtreecommitdiffhomepage
path: root/test/cpp/util/benchmark_config.cc
diff options
context:
space:
mode:
Diffstat (limited to 'test/cpp/util/benchmark_config.cc')
-rw-r--r--test/cpp/util/benchmark_config.cc14
1 files changed, 8 insertions, 6 deletions
diff --git a/test/cpp/util/benchmark_config.cc b/test/cpp/util/benchmark_config.cc
index 91fbbf9677..3c38221b4c 100644
--- a/test/cpp/util/benchmark_config.cc
+++ b/test/cpp/util/benchmark_config.cc
@@ -37,7 +37,8 @@
DEFINE_bool(enable_log_reporter, true,
"Enable reporting of benchmark results through GprLog");
-DEFINE_bool(report_metrics_db, false, "True if metrics to be reported to performance database");
+DEFINE_bool(report_metrics_db, false,
+ "True if metrics to be reported to performance database");
DEFINE_string(hashed_id, "", "Hash of the user id");
@@ -45,7 +46,8 @@ DEFINE_string(test_name, "", "Name of the test being executed");
DEFINE_string(sys_info, "", "System information");
-DEFINE_string(server_address, "localhost:50052", "Address of the performance database server");
+DEFINE_string(server_address, "localhost:50052",
+ "Address of the performance database server");
DEFINE_string(tag, "", "Optional tag for the test");
@@ -69,10 +71,10 @@ static std::shared_ptr<Reporter> InitBenchmarkReporters() {
composite_reporter->add(
std::unique_ptr<Reporter>(new GprLogReporter("LogReporter")));
}
- if(FLAGS_report_metrics_db) {
- composite_reporter->add(
- std::unique_ptr<Reporter>(new PerfDbReporter("PerfDbReporter", FLAGS_hashed_id, FLAGS_test_name,
- FLAGS_sys_info, FLAGS_server_address, FLAGS_tag)));
+ if (FLAGS_report_metrics_db) {
+ composite_reporter->add(std::unique_ptr<Reporter>(
+ new PerfDbReporter("PerfDbReporter", FLAGS_hashed_id, FLAGS_test_name,
+ FLAGS_sys_info, FLAGS_server_address, FLAGS_tag)));
}
return std::shared_ptr<Reporter>(composite_reporter);