-
Notifications
You must be signed in to change notification settings - Fork 527
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[RunAllTests] Fix part of #2844: work around Bazel-specific CI issue that's causing an OpenJDK crash/flake #2846
Conversation
Update Bazel to use JDK 9 in CI for building per https://docs.bazel.build/versions/master/bazel-and-java.html#configuring-the-jdk.
Update Bazel builds to use faster tools repository, and to use JDK 9 for building.
Remove tools override since it's now part of ~/.bazelrc.
Attempt to use the solution described in: bazelbuild/bazel#3236 (comment).
Is this still required? |
@vinitamurthi this is expected to help, but it may not be sufficient to fully fix the Bazel-caused flakes. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Conflicts: .github/workflows/build_tests.yml .github/workflows/unit_tests.yml
Thanks all! Enabling auto-merge after resolving conflicts since some of the changes here may help with work I'm doing in #1861 to make Bazel CI runs a bit faster. |
Fix part of #2844.
This attempts to fix part of #2844 by normalizing test compiling/running on JDK 9 (for parity with Gradle tests--see #2845), and by working around what appears to be a resource constraint issue Bazel is hitting. For the latter, see bazelbuild/bazel#3236 (comment). All configuration changes in this PR are done via changes to the CI environment's
~/.bazelrc
file, so nothing here should affect local builds.Note that configuring Java versions in Bazel is complicated. In particular, at any time there can be 5 different versions of Java at play:
Now, from what I can tell, I think we only need to configure (1) since (2) should already be using the correct version of Java (JDK 9). We do want the majority of the build to be on JDK 9 since that's what we're running on, but this isn't super important. See also https://docs.bazel.build/versions/master/bazel-and-java.html#configuring-the-jdk & bazelbuild/bazel#5594 for more details on how this Java resolution works.
Finally, similar to #2845 this cannot be observed as "correct" until we observe the flake itself disappearing over the next few weeks.