Skip to content

Commit 2442a2e

Browse files
keertkcushonGooglerlarsrc-google
authored
[6.2.0] default_java_toolchain.bzl cherry-picks to fix regression (bazelbuild#18225)
* Disable 'IgnoredPureGetter' See bazelbuild#16996 PiperOrigin-RevId: 494921387 Change-Id: I53dee7da0f321c50e303816b5fb85eda45949efa * Make LenientFormatStringValidation a warning PiperOrigin-RevId: 502649182 Change-Id: Ia69e5be9da817d7c25e51cad5086309515bb280a * Make ReturnMissingNullable a warning PiperOrigin-RevId: 502710013 Change-Id: I80f35a248623d293e187d481dc5ffbaff08bf25f * Redirect JVM warnings to stderr in general. In particular this avoids problems with JVM warnings clashing with the worker protocol, but also matches Blaze's idea of where output goes better. PiperOrigin-RevId: 524826411 Change-Id: If4c78ac5f63dfd4596da924c12552f6335b8034d --------- Co-authored-by: Googler <[email protected]> Co-authored-by: Googler <[email protected]> Co-authored-by: Googler <[email protected]>
1 parent 3624c74 commit 2442a2e

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

tools/jdk/default_java_toolchain.bzl

+9
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,11 @@ BASE_JDK9_JVM_OPTS = [
3838
# TODO(b/64485048): Disable this option in persistent worker mode only.
3939
# Disable symlinks resolution cache since symlinks in exec root change
4040
"-Dsun.io.useCanonCaches=false",
41+
42+
# Since https://bugs.openjdk.org/browse/JDK-8153723, JVM logging goes to stdout. This
43+
# makes it go to stderr instead.
44+
"-Xlog:disable",
45+
"-Xlog:all=warning:stderr:uptime,level,tags",
4146
]
4247

4348
JDK9_JVM_OPTS = BASE_JDK9_JVM_OPTS
@@ -49,7 +54,11 @@ DEFAULT_JAVACOPTS = [
4954
"-parameters",
5055
# https://github.com/bazelbuild/bazel/issues/15219
5156
"-Xep:ReturnValueIgnored:OFF",
57+
# https://github.com/bazelbuild/bazel/issues/16996
58+
"-Xep:IgnoredPureGetter:OFF",
5259
"-Xep:EmptyTopLevelDeclaration:OFF",
60+
"-Xep:LenientFormatStringValidation:OFF",
61+
"-Xep:ReturnMissingNullable:OFF",
5362
]
5463

5564
# java_toolchain parameters without specifying javac, java.compiler,

0 commit comments

Comments
 (0)