Skip to content
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

release java_tools javac11-v2.0 #8

Closed
iirina opened this issue May 29, 2019 · 8 comments
Closed

release java_tools javac11-v2.0 #8

iirina opened this issue May 29, 2019 · 8 comments
Assignees
Labels
P1 I'll work on this now. (Assignee required) release

Comments

@iirina
Copy link
Contributor

iirina commented May 29, 2019

The release must contain bazelbuild/bazel#8490

This issue follows the instructions under java_tools release process.

@iirina iirina pinned this issue May 29, 2019
@iirina iirina self-assigned this May 29, 2019
@iirina iirina added the P1 I'll work on this now. (Assignee required) label May 29, 2019
@iirina
Copy link
Contributor Author

iirina commented May 29, 2019

Creating rc1:
bazel commit hash: 1de8aa398434ffb2e5c97d35ba97a80ea70a79db
build: https://buildkite.com/bazel-trusted/java-tools-binaries-java/builds/107

$ export COMMIT_HASH=1de8aa398434ffb2e5c97d35ba97a80ea70a79db 
$ export JDK_VERSION=11 
$ export NEW_VERSION=2.0 
$ export RC=1 
$ src/create_java_tools_release.sh --commit_hash $COMMIT_HASH --java_tools_version $NEW_VERSION --java_version $JDK_VERSION --rc $RC --release false

release_candidates/javac11/v2.0/java_tools_javac11_linux-v2.0-rc1.zip f70b20a9b8b53e85b00bc78d097663ea825ce58fc0824f4d9639e6e0156a3391
release_candidates/javac11/v2.0/java_tools_javac11_windows-v2.0-rc1.zip 8f3c20b8fb2253fc0e14ab72ab2156814f6f326d822937f08bdc89399017ce3d
release_candidates/javac11/v2.0/java_tools_javac11_darwin-v2.0-rc1.zip 898f4755287bd63c3c2c43442c5b69f94a1a350d2ece691de94d7d4e942df728

@iirina
Copy link
Contributor Author

iirina commented May 29, 2019

Bazel upgrade is happening in bazelbuild/bazel#8498

Bazel tests pipeline started: https://buildkite.com/bazel/bazel-bazel-github-presubmit/builds/3129

@iirina
Copy link
Contributor Author

iirina commented May 29, 2019

The tests fail due to a circular dependency:

ERROR: /var/lib/buildkite-agent/.cache/bazel/_bazel_buildkite-agent/ec321eb2cc2d0f8f91b676b6d4c66c29/sandbox/linux-sandbox/4608/execroot/io_bazel/_tmp/560d84240c3e286e5662ef42830cec54/_bazel_buildkite-agent/b67d64e301e5c5e87c5776aec07a8d26/external/bazel_tools/tools/jdk/BUILD:59:1: in java_toolchain_alias rule @bazel_tools//tools/jdk:current_java_toolchain: cycle in dependency graph:
//foo:gen
//bar:bar-java (host)
.-> @bazel_tools//tools/jdk:current_java_toolchain (host)
|   @bazel_tools//tools/jdk:legacy_current_java_toolchain (host)
|   @bazel_tools//tools/jdk:remote_toolchain (host)
|   @remote_java_tools_linux//:toolchain (host)
|   @remote_java_tools_linux//:jacoco_coverage_runner (host)
`-- @bazel_tools//tools/jdk:current_java_toolchain (host)

This requires a fix in bazel and a new rc.

@iirina
Copy link
Contributor Author

iirina commented May 31, 2019

Fix was sent in bazelbuild/bazel#8529. A new RC can be created after bazelbuild/bazel#8529 is merged in bazel.

bazel-io pushed a commit to bazelbuild/bazel that referenced this issue May 31, 2019
Bazel 0.26 added the `jacocorunner` attribute on `java_toolchain`. Java targets now fail when using the new host java_toolchain because of a dependency cycle:

```
@bazel_tools//tools/jdk:JacocoCoverageRunner
@bazel_tools//tools/jdk:current_java_toolchain
@bazel_tools//tools/jdk:legacy_current_java_toolchain
@bazel_tools//tools/jdk:remote_toolchain
@remote_java_tools_linux//:toolchain
.-> @remote_java_tools_linux//:jacoco_coverage_runner (host)
|   @bazel_tools//tools/jdk:current_java_toolchain (host)
|   @bazel_tools//tools/jdk:legacy_current_java_toolchain (host)
|   @bazel_tools//tools/jdk:remote_toolchain (host)
|   @remote_java_tools_linux//:toolchain (host)
`-- @remote_java_tools_linux//:jacoco_coverage_runner (host)
```

The dependency is happening because `jacocorunner` in `java_toolchain` was declared as a `java_import` which depends on the host `java_toolchain`. The issue was not caught because we only run the java integration tests with `--java_toolchain` built at head. If we had run the tests also with `--host_java_toolchain` the issue would have been caught (see #8530).

This PR does the following:
* Makes `jacocorunner` attribute a `filegroup` instead of a `java_import` to avoid the dependency cycle.
* Converts the type of `jacocoRunner` in `JavaToolchain` from a `TransitiveInfoCollection` to `FilesToRunProvider` to be able to retrieve the executable jar from the `filegroup`.
* Adds testing with `--host_java_toolchain` of the java_tools built as head

This is a blocker for the new java_tools release (bazelbuild/java_tools#8).

Closes #8529.

PiperOrigin-RevId: 250876908
@iirina
Copy link
Contributor Author

iirina commented May 31, 2019

Creating rc2:
bazel commit hash: 3dc59e400a9e0a57f34aa990ec410a1b2af760d3
build: https://buildkite.com/bazel-trusted/java-tools-binaries-java/builds/108

$ export COMMIT_HASH=3dc59e400a9e0a57f34aa990ec410a1b2af760d3
$ export JDK_VERSION=11
$ export NEW_VERSION=2.0
$ export RC=2
$ src/create_java_tools_release.sh --commit_hash $COMMIT_HASH --java_tools_version $NEW_VERSION --java_version $JDK_VERSION --rc $RC --release false

release_candidates/javac11/v2.0/java_tools_javac11_linux-v2.0-rc2.zip ff35a39d943dd592368b0340480de0b22cd8792743b4289182fe0f6bb91d0355
release_candidates/javac11/v2.0/java_tools_javac11_windows-v2.0-rc2.zip f5268bd0ae88195c36f8dd8fc3eeae9b5ed83c122bde7c16d69cd8215d832620
release_candidates/javac11/v2.0/java_tools_javac11_darwin-v2.0-rc2.zip 5f285e710408a1d8ba5c08aac53f54b919c367cdb6fafc3c8f67573db6a9fa09

@iirina
Copy link
Contributor Author

iirina commented Jun 3, 2019

Testing for rc2 failed with errors like these:

external/remote_java_tools_linux/java_tools/ijar/ijar: /usr/lib/x86_64-linux-gnu/libstdc++.so.6: version `GLIBCXX_3.4.21' not found (required by external/remote_java_tools_linux/java_tools/ijar/ijar)

This happened because the java tools Buildkite pipeline was recently updated by the EngProd team to build the linux artifact on Ubuntu 18 instead of Ubuntu 14.

I update the pipeline settings to build on Ubuntu 14 and created rc3:

bazel commit hash: 00b5dadc485f968bced9dc152d9f391a3dc1992b
build: https://buildkite.com/bazel-trusted/java-tools-binaries-java/builds/111

$ export COMMIT_HASH=00b5dadc485f968bced9dc152d9f391a3dc1992b
$ export JDK_VERSION=11
$ export NEW_VERSION=2.0
$ export RC=3
$ src/create_java_tools_release.sh --commit_hash $COMMIT_HASH --java_tools_version $NEW_VERSION --java_version $JDK_VERSION --rc $RC --release false

release_candidates/javac11/v2.0/java_tools_javac11_linux-v2.0-rc3.zip 5714c0a34c99b5a474b281c5e0f2019c8a24594a8288062dc307faefd1738fac
release_candidates/javac11/v2.0/java_tools_javac11_windows-v2.0-rc3.zip ff5f13b93a048518f7263932d5a26d60c4d56d0a969cf8b226015bc85dedb57d
release_candidates/javac11/v2.0/java_tools_javac11_darwin-v2.0-rc3.zip b94f14d0b1d491da988af1f2f63abe1fee42a880d7e8ca666a1df4a1e03ba37a

@iirina
Copy link
Contributor Author

iirina commented Jun 3, 2019

My change in the buildkite pipeline settings was not enough to build on Ubuntu 14. I sent a PR to change this setting in the pipeline yml configuration file as well (bazelbuild/continuous-integration#695)

New build for RC 4: https://buildkite.com/bazel-trusted/java-tools-binaries-java/builds/113
bazel commit hash: 50c876e337a6e40ade7069d46649ae71296cfc14

$ export COMMIT_HASH=50c876e337a6e40ade7069d46649ae71296cfc14
$ export JDK_VERSION=11
$ export NEW_VERSION=2.0
$ export RC=4
$ src/create_java_tools_release.sh --commit_hash $COMMIT_HASH --java_tools_version $NEW_VERSION --java_version $JDK_VERSION --rc $RC --release false

release_candidates/javac11/v2.0/java_tools_javac11_linux-v2.0-rc4.zip 074d624fb34441df369afdfd454e75dba821d5d54932fcfee5ba598d17dc1b99
release_candidates/javac11/v2.0/java_tools_javac11_windows-v2.0-rc4.zip 2c3fc0ce7d30d60e26f4b8a36e2eadcf9e6a9d5a51b667d3d13b78db53b24251
release_candidates/javac11/v2.0/java_tools_javac11_darwin-v2.0-rc4.zip 0ceb0c9ff91256fe33508306bc9cd9e188dcca38df78e70839d426bdaef67a38

@iirina
Copy link
Contributor Author

iirina commented Jun 3, 2019

All tests passed. Releasing RC4:

$ export JDK_VERSION=11
$ export NEW_VERSION=2.0
$ export RC=4
$ src/create_java_tools_release.sh --java_tools_version $NEW_VERSION --java_version $JDK_VERSION --rc $RC --release true

releases/javac11/v2.0/java_tools_javac11_linux-v2.0.zip 074d624fb34441df369afdfd454e75dba821d5d54932fcfee5ba598d17dc1b99
releases/javac11/v2.0/java_tools_javac11_windows-v2.0.zip 2c3fc0ce7d30d60e26f4b8a36e2eadcf9e6a9d5a51b667d3d13b78db53b24251
releases/javac11/v2.0/java_tools_javac11_darwin-v2.0.zip 0ceb0c9ff91256fe33508306bc9cd9e188dcca38df78e70839d426bdaef67a38

bazel-io pushed a commit to bazelbuild/bazel that referenced this issue Jun 3, 2019
Upgrade the java tools version in Bazel to `javac_11-v2.0`.

This PR fixes reported errors of `missing input file '@remote_java_tools_darwin//:Genclass'` (e.g. bazelbuild/intellij#845).

Also update the java_tools version for javac 9 and 10 that are used in tests. New java_tools releases for javac 9 and 10 were required because of new bazel API (`java_toolchain` now has an `jacocorunner` attribute).

The detailed release of `javac_11-v2.0` can be found in bazelbuild/java_tools#8.
The detailed release of java_tools `javac9-v2.0` and `javac10-v4.0` can be found in bazelbuild/java_tools#10.

Closes #8498.

PiperOrigin-RevId: 251245301
@iirina iirina closed this as completed Jun 4, 2019
@iirina iirina unpinned this issue Jun 4, 2019
irengrig pushed a commit to irengrig/bazel that referenced this issue Jun 18, 2019
Bazel 0.26 added the `jacocorunner` attribute on `java_toolchain`. Java targets now fail when using the new host java_toolchain because of a dependency cycle:

```
@bazel_tools//tools/jdk:JacocoCoverageRunner
@bazel_tools//tools/jdk:current_java_toolchain
@bazel_tools//tools/jdk:legacy_current_java_toolchain
@bazel_tools//tools/jdk:remote_toolchain
@remote_java_tools_linux//:toolchain
.-> @remote_java_tools_linux//:jacoco_coverage_runner (host)
|   @bazel_tools//tools/jdk:current_java_toolchain (host)
|   @bazel_tools//tools/jdk:legacy_current_java_toolchain (host)
|   @bazel_tools//tools/jdk:remote_toolchain (host)
|   @remote_java_tools_linux//:toolchain (host)
`-- @remote_java_tools_linux//:jacoco_coverage_runner (host)
```

The dependency is happening because `jacocorunner` in `java_toolchain` was declared as a `java_import` which depends on the host `java_toolchain`. The issue was not caught because we only run the java integration tests with `--java_toolchain` built at head. If we had run the tests also with `--host_java_toolchain` the issue would have been caught (see bazelbuild#8530).

This PR does the following:
* Makes `jacocorunner` attribute a `filegroup` instead of a `java_import` to avoid the dependency cycle.
* Converts the type of `jacocoRunner` in `JavaToolchain` from a `TransitiveInfoCollection` to `FilesToRunProvider` to be able to retrieve the executable jar from the `filegroup`.
* Adds testing with `--host_java_toolchain` of the java_tools built as head

This is a blocker for the new java_tools release (bazelbuild/java_tools#8).

Closes bazelbuild#8529.

PiperOrigin-RevId: 250876908
irengrig pushed a commit to irengrig/bazel that referenced this issue Jun 18, 2019
Upgrade the java tools version in Bazel to `javac_11-v2.0`.

This PR fixes reported errors of `missing input file '@remote_java_tools_darwin//:Genclass'` (e.g. bazelbuild/intellij#845).

Also update the java_tools version for javac 9 and 10 that are used in tests. New java_tools releases for javac 9 and 10 were required because of new bazel API (`java_toolchain` now has an `jacocorunner` attribute).

The detailed release of `javac_11-v2.0` can be found in bazelbuild/java_tools#8.
The detailed release of java_tools `javac9-v2.0` and `javac10-v4.0` can be found in bazelbuild/java_tools#10.

Closes bazelbuild#8498.

PiperOrigin-RevId: 251245301
irengrig pushed a commit to irengrig/bazel that referenced this issue Jul 15, 2019
Bazel 0.26 added the `jacocorunner` attribute on `java_toolchain`. Java targets now fail when using the new host java_toolchain because of a dependency cycle:

```
@bazel_tools//tools/jdk:JacocoCoverageRunner
@bazel_tools//tools/jdk:current_java_toolchain
@bazel_tools//tools/jdk:legacy_current_java_toolchain
@bazel_tools//tools/jdk:remote_toolchain
@remote_java_tools_linux//:toolchain
.-> @remote_java_tools_linux//:jacoco_coverage_runner (host)
|   @bazel_tools//tools/jdk:current_java_toolchain (host)
|   @bazel_tools//tools/jdk:legacy_current_java_toolchain (host)
|   @bazel_tools//tools/jdk:remote_toolchain (host)
|   @remote_java_tools_linux//:toolchain (host)
`-- @remote_java_tools_linux//:jacoco_coverage_runner (host)
```

The dependency is happening because `jacocorunner` in `java_toolchain` was declared as a `java_import` which depends on the host `java_toolchain`. The issue was not caught because we only run the java integration tests with `--java_toolchain` built at head. If we had run the tests also with `--host_java_toolchain` the issue would have been caught (see bazelbuild#8530).

This PR does the following:
* Makes `jacocorunner` attribute a `filegroup` instead of a `java_import` to avoid the dependency cycle.
* Converts the type of `jacocoRunner` in `JavaToolchain` from a `TransitiveInfoCollection` to `FilesToRunProvider` to be able to retrieve the executable jar from the `filegroup`.
* Adds testing with `--host_java_toolchain` of the java_tools built as head

This is a blocker for the new java_tools release (bazelbuild/java_tools#8).

Closes bazelbuild#8529.

PiperOrigin-RevId: 250876908
irengrig pushed a commit to irengrig/bazel that referenced this issue Jul 15, 2019
Upgrade the java tools version in Bazel to `javac_11-v2.0`.

This PR fixes reported errors of `missing input file '@remote_java_tools_darwin//:Genclass'` (e.g. bazelbuild/intellij#845).

Also update the java_tools version for javac 9 and 10 that are used in tests. New java_tools releases for javac 9 and 10 were required because of new bazel API (`java_toolchain` now has an `jacocorunner` attribute).

The detailed release of `javac_11-v2.0` can be found in bazelbuild/java_tools#8.
The detailed release of java_tools `javac9-v2.0` and `javac10-v4.0` can be found in bazelbuild/java_tools#10.

Closes bazelbuild#8498.

PiperOrigin-RevId: 251245301
@iirina iirina added the release label Aug 21, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P1 I'll work on this now. (Assignee required) release
Projects
None yet
Development

No branches or pull requests

1 participant