[ http://jira.codehaus.org/browse/MNG-275?page=comments#action_32101 ]
     
Brett Porter commented on MNG-275:
----------------------------------

I'd like to consider making the maven-plugin-api dependency optional, and 
review the split between maven-monitor and maven-plugin.

what is provided by the plugin interface is:
- execute() method
- setLog(Logger logger) method

The execute method can be looked up using reflection if the class does not 
implement Plugin.

While this could be done for setLog, the Logger must be something... I suggest 
that maven-plugin-api should provider the Logger interface (and only an 
interface - not an implementation), and a plugin wishing to Log will have to 
implement the Plugin interface (or extend AbstractPlugin).

So anything could use these beans by simply looking up and running the 
execute() method, and I believe that such means would already be valid Ant 
tasks as is as well as mojos (with appropriate metadata).

Then, if it implements plugin the setLog method can be called with a 
MavenPluginLogger or AntLogger implementation, etc.

This reduces the relevance of maven-monitor, and it may be appropriate to just 
take the interface from there, and then use plexus logging inside Maven itself 
(and provide a plexus logging implementation of the plugin's logger interface).


> design and publish the Mojo API
> -------------------------------
>
>          Key: MNG-275
>          URL: http://jira.codehaus.org/browse/MNG-275
>      Project: m2
>         Type: Task
>   Components: design
>     Reporter: Brett Porter
>      Fix For: 2.0-alpha-2

>
>
> we need to solidify the Mojo API so that others can start writing them with 
> confidence.
> This includes:
> - strategy for dealing with types
> - dealing with responses
> - reviewing logging and events
> - considering whether extending a class is too cumbersome
> - what basic types we might want to provide without going overboard
> anything else?

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to