You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Piotr Zygielo (Jira)" <ji...@apache.org> on 2022/04/06 16:34:00 UTC

[jira] [Created] (MJAVADOC-710) Usage of removed or replaced property does not cause the build to fail

Piotr Zygielo created MJAVADOC-710:
--------------------------------------

             Summary: Usage of removed or replaced property does not cause the build to fail
                 Key: MJAVADOC-710
                 URL: https://issues.apache.org/jira/browse/MJAVADOC-710
             Project: Maven Javadoc Plugin
          Issue Type: Bug
    Affects Versions: 3.3.2
            Reporter: Piotr Zygielo


Per https://issues.apache.org/jira/browse/MJAVADOC-509?focusedCommentId=16581261
{quote}Yes, additionalParam was replaced by additionalOptions in MJAVADOC-475(https://issues.apache.org/jira/browse/MJAVADOC-475) and the build will fail with 3.0.0 if this property is used.
{quote}
However current implementation does not do that. And as far as I've checked - the original implementation didn't do in 3.0.0 neither.
This is due to {{mojo.getConfiguration()}} in {{AbstractJavadocMojo.verifyRemovedParameter}} having only parameters plugin committed for, and not all from {{<configuration>}} element. Not at the moment of goal execution, at least.

This causes problems when upgrading from pre-3 plugin as {{additionalparam}} is silently ignored.

I see similar case is dealt in following way:
 - [https://github.com/apache/maven-jar-plugin/blob/0ad60f4f2862bf896b6c0dc57ea5a6999c49b0d4/src/main/java/org/apache/maven/plugins/jar/AbstractJarMojo.java#L107-L115]
 - [https://github.com/apache/maven-deploy-plugin/blob/36a2030c8851e21cd1e0bec01c3cea4dc6055a48/src/main/java/org/apache/maven/plugins/deploy/DeployFileMojo.java#L180-L188]
 - and few others

which is to have {{@Deprecated}} parameter, and its presence is used for breaking the build.



--
This message was sent by Atlassian Jira
(v8.20.1#820001)