[bazel] Use newer mechanism for hermetic java toolchain
@@ -4,7 +4,8 @@ build --flag_alias=pin_browsers=//common:pin_browsers
build --flag_alias=headless=//common:headless
# Set the default java toolchain
-build --java_toolchain=@bazel_tools//tools/jdk:toolchain_java11
+build --java_runtime_version=remotejdk_11
+build --tool_java_language_version=11
# We target java 8 by default
build --javacopt="--release 8"
