Parameterize the Java logging formatter class. Allow subclasses of StartupOptions to override the formatter passed to the Java logging configuration. This is to allow us to override this value internally for Blaze in an attempt to homogenize things. -- PiperOrigin-RevId: 146668430 MOS_MIGRATED_REVID=146668430
diff --git a/src/main/cpp/startup_options.cc b/src/main/cpp/startup_options.cc index 876b91d..f54c900 100644 --- a/src/main/cpp/startup_options.cc +++ b/src/main/cpp/startup_options.cc
@@ -56,7 +56,8 @@ connect_timeout_secs(10), invocation_policy(NULL), client_debug(false), - use_custom_exit_code_on_abrupt_exit(true) { + use_custom_exit_code_on_abrupt_exit(true), + java_logging_formatter("java.util.logging.SimpleFormatter") { bool testing = !blaze::GetEnv("TEST_TMPDIR").empty(); if (testing) { output_root = MakeAbsolute(blaze::GetEnv("TEST_TMPDIR")); @@ -409,7 +410,7 @@ "java.util.logging.FileHandler.limit=50000\n" "java.util.logging.FileHandler.count=1\n" "java.util.logging.FileHandler.formatter=" - "java.util.logging.SimpleFormatter\n", + + java_logging_formatter + "\n", propFile)) { perror(("Couldn't write logging file " + propFile).c_str()); } else {