GoogleCloudPlatform / GoogleCloudPlatform/cloud-opensource-java

In JLBP-19 add a comment on how to use both module path and class path at the same time

Offen
#1,898 3 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
best practices question
Vorherrschende Sprache
Java
Sterne
163
Forks
80
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

https://jlbp.dev/JLBP-19 says

> If classes from the same package appear in Maven artifacts with different group IDs or different artifact IDs, it is easy to construct a classpath that splits packages. This is a problem even if individual classes do not overlap. For example, the google-cloud-vision Java API client places protobufs in `com.google.api.grpc:proto-google-cloud-vision-v1` and gRPC stubs in `com.google.api.grpc:grpc-google-cloud-vision-v1`. Since both artifacts contain classes in the com.google.cloud.vision.v1 package, these two artifacts cannot be used together after Java 8.

If users choose to place these split-package libraries in class path rather than module path, they can use the libraries in Java 11.

ref https://blog.joda.org/2018/03/jpms-negative-benefits.html

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.