You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Elliotte Rusty Harold (Jira)" <ji...@apache.org> on 2019/12/23 11:42:00 UTC

[jira] [Commented] (MNG-5563) Ensuring only the available parameters are allowed

    [ https://issues.apache.org/jira/browse/MNG-5563?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17002221#comment-17002221 ] 

Elliotte Rusty Harold commented on MNG-5563:
--------------------------------------------

Make this unconditional, not optional. 

> Ensuring only the available parameters are allowed
> --------------------------------------------------
>
>                 Key: MNG-5563
>                 URL: https://issues.apache.org/jira/browse/MNG-5563
>             Project: Maven
>          Issue Type: Improvement
>          Components: POM
>            Reporter: S. Ali Tokmen
>            Priority: Major
>             Fix For: Issues to be reviewed for 4.x
>
>
> I am one of the owners of Codehaus CARGO, which has a Maven2/Maven3 plugin; and would have an improvement request with regards to how parameters are managed.
> Currently, what happens is that if a user unwillingly puts a parameter in the wrong place then the plugin execution continues as is. One of the latest such issues one of the users has had can be found on http://cargo.996258.n3.nabble.com/Maven-plugin-and-javaagent-tp18075.html
> As an example, I can write the below POM and build still works (even thought the MOJO has no parameter called "foo"):
> {noformat}
>   <plugin>
>     <groupId>org.codehaus.cargo</groupId>
>     <artifactId>cargo-maven2-plugin</artifactId>
>     <version>1.4.6</version>
>     <configuration>
>       <foo>
>         bar
>       </foo>
>     </configuration>
>   </plugin>
> {noformat}
> It would be good for the MOJO developer to be ablo instruct by MOJO to fail if there is an unknown parameter in the configuration.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)