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

Robert Scholte commented on MPLUGIN-350:
----------------------------------------

After a small investigation, using in/out as elements won't work, since parsing 
is done differently inside Maven.

{code:title=org.apache.maven.plugin.descriptor.PluginDescriptorBuilder#buildComponentDescriptor(PlexusConfiguration,PluginDescriptor)}
PlexusConfiguration[] parameterConfigurations = c.getChild( "parameters" 
).getChildren( "parameter" );
{code}
However, it is only parsing known elements and attributes, the unknowns are 
simple ignored.

And I noticed that Files will be challenging. In case a file refers to a 
sourceDirectory, you probably want to very (a subset of) the sourceFiles.
In case a file simply points to basedir, you don't want to check every file or 
directory underneath it. One conclusion could be that basedir alone is unwanted 
and you probably want to refer to a specific file or directory instead. We need 
to be very clear about the usage and implications.


> Split @Parameter into @Input and @Output
> ----------------------------------------
>
>                 Key: MPLUGIN-350
>                 URL: https://issues.apache.org/jira/browse/MPLUGIN-350
>             Project: Maven Plugin Tools
>          Issue Type: New Feature
>            Reporter: Robert Scholte
>            Priority: Major
>
> By knowing if parameters are input or output parameters, it is possible to 
> improve our builds. It will be possible to create DAGs and chain the 
> execution blocks much smarter.
> The Maven Extension created by Gradle heavily relies on this kind of 
> information.
> It is probably easier to use new annotations instead of adding a (required) 
> status-field to @Parameter
> Looking at the {{plugin.xml}} it looks quite easy to solve this and stay 
> backwards compatible: the file looks now like:
> {code:xml}
>   <parameters>
>     <parameter>
>       ...
>     </parameter>
>   </parameters>
> {code}
> With plexus-magic the following should still work:
> {code:xml}
>   <parameters>
>     <input>
>       ...
>     </input>
>     <output>
>       ...
>     </output>
>   </parameters>
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to