[7.0.0] Fix JVM repository rules with Bzlmod #20088
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
http_jar
andjvm_{maven_}import_external
rules load from@rules_java
as resolved within@bazel_tools
rather than the calling module extension's repository.jvm_maven_import_external
to generate a target name for the jar that makes the shorthand@my_import
form work with Bzlmod.http_jar
rule with the full repo mapping forbazel_tools
so that it seesrules_java
, while still loadinghttp_archive
with a trivial repo mapping to prevent a cycle during module repo creation. This requires introducing a new key type forBzlLoadFunction
.Closes #19997.
PiperOrigin-RevId: 579002601
Change-Id: I94c85e9759d0913384b10b9bbd0d0cb960cdd89a