gnodet commented on code in PR #618:
URL: https://github.com/apache/maven-jar-plugin/pull/618#discussion_r4294034708


##########
src/main/java/org/apache/maven/plugins/jar/AbstractJarMojo.java:
##########
@@ -116,11 +114,10 @@ public abstract class AbstractJarMojo implements 
org.apache.maven.api.plugin.Moj
     protected Session session;
 
     /**
-     * The archive configuration to use. See <a 
href="http://maven.apache.org/shared/maven-archiver/index.html";>Maven
-     * Archiver Reference</a>.
+     * The archive configuration to use.
      */
     @Parameter
-    protected MavenArchiveConfiguration archive = new 
MavenArchiveConfiguration();
+    protected ArchiveConfiguration archive = new ArchiveConfiguration();

Review Comment:
   The type change from `MavenArchiveConfiguration` to `ArchiveConfiguration` 
is a binary breaking change for any code that extends `AbstractJarMojo` and 
references the `archive` field by type. In practice, this is rare — 
`maven-jar-plugin` is a packaging plugin, not a library, and extending its 
mojos is an unsupported use case.
   
   Source compatibility is also broken: any downstream class that declared a 
variable of type `MavenArchiveConfiguration` or called methods specific to that 
type would need to be updated.
   
   That said, this PR removes `maven-archiver` from the classpath entirely, so 
`MavenArchiveConfiguration` would not even be available at compile time for 
consumers anyway — the field-type change is a consequence of the dependency 
removal, not an independent incompatibility.
   
   The changelog / release notes should document this as a migration note for 
users who may have extended `AbstractJarMojo` directly.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to