refactor(internal/config): remove deprecated libraries_bom_version from JavaModule#6584
Open
sofisl wants to merge 5 commits into
Open
refactor(internal/config): remove deprecated libraries_bom_version from JavaModule#6584sofisl wants to merge 5 commits into
sofisl wants to merge 5 commits into
Conversation
…etadata
Remove the Java-specific mapping in RepoMetadataTransport that translated
transport values to "http" or "both". Now it returns the standard values
("grpc", "rest", "grpc+rest") directly, aligning Java with other languages.
Fixes googleapis#4854
Contributor
There was a problem hiding this comment.
Code Review
This pull request removes the unused LibrariesBOMVersion field from the Java configuration and simplifies the RepoMetadataTransport logic for Java to return the transport directly, updating associated tests accordingly. The review feedback suggests refactoring the findBOMVersion function signature to remove the library parameter, which is now unused after these changes.
I am having trouble creating individual review comments. Click here to see my feedback.
internal/librarian/java/generate.go (341-343)
Removing the check for library.Java.LibrariesBOMVersion makes the library parameter in findBOMVersion unused. Consider refactoring the function signature to remove the library parameter to keep the code clean and adhere to the YAGNI principle.
References
- Avoid passing variables to functions for future, unimplemented use cases. Adhere to the YAGNI (You Ain't Gonna Need It) principle.
g-husam
approved these changes
Jun 30, 2026
g-husam
left a comment
Contributor
There was a problem hiding this comment.
LGTM but might want someone more familiar to review
JoeWang1127
reviewed
Jun 30, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Finalizes the migration to JavaDefault by removing the deprecated libraries_bom_version field from the JavaModule struct, its merging logic, and its library-level fallback check in the generator. This is backwards compatibile because it is only defined once at the global default.java level in librarian.yaml in google-cloud-java. Follow up to #6447.
Fixes #5171