jira.codehaus.org

  • Log In Access more options
    • Online Help
    • Keyboard Shortcuts
    • About JIRA
    • JIRA Credits
    • What?s New
  • Dashboards Access more options (Alt+d)
  • Projects Access more options (Alt+p)
  • Issues Access more options (Alt+i)
  • Maven 2 & 3
  • MNG-377

implement group/artifactID looked by plugin prefix

  • Log In
  • Views
    • XML
    • Word
    • Printable

Details

  • Type: Improvement Improvement
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: None
  • Fix Version/s: 2.0-beta-1
  • Component/s: Plugins and Lifecycle
  • Labels:
    None

Description

We have a default rule which will be used as a fallback, where the
prefix "idea" is turned into "maven-idea-plugin". This will be retained
if no other information is found.

Before applying the default rule, some more metadata from the repository
will be consulted. This will be stored at the group level, and named
"plugins.xml".

/org/apache/maven/plugins/plugins.xml
/org.apache.maven.plugins/plugins.xml

While this could potentially include version information as well, it is
worth being able to check these on a plugin-by-plugin basis, and it also
fits with the potential RELEASE specifier on dependencies. This could be
reconsidered in future versions.

Format of the file for now is simple:
<prefixes>
<groupId>org.apache.maven.plugins</groupId>
<plugins>
<plugin>
<prefix>idea</prefix>
<artifactId>maven-idea-plugin</artifactId>
</plugin>
...
</plugins>
</prefixes>

This particular file will also be updated at release time for a plugin
(though it should rarely be necessary as only new additions need to be
published back).

The list of group IDs to search will be configured from settings.xml,
with the default being just org.apache.maven.plugins. The process will
be to load the plugins.xml file from each of the configured groups, then
build the map of prefixes to plugin group/artifactIDs. If there is a
clash, initially it should fail. We might allow using the first
discovered or some other resolution mechanism, but would hope not to get
that situation as a goal representation might start taking on different
meanings in different contexts.

Activity

Ascending order - Click to sort in descending order
  • All
  • Comments
  • Work Log
  • History
  • Activity
Hide
Permalink
John Casey added a comment - 21/Jun/05 11:29 AM

I think I've got the issue condensed to the following:

----------------------------------

requirements
===============

  • allow users to specify a list of plugin groupId's to search
  • when a plugin is released (deployed?), a plugins.xml file under it's groupId
    should be modified to ensure that the plugin's information is provided.
  • a mapping prefix to plugin g:a will be constructed in memory using the user's
    search groups
  • default over to org.apache.maven.plugins if no matches are found, or if the
    search-groups are empty.
  • plugin.xml files can be cached locally, but an attempt should be made in all
    'normal' cases (non-offline mode) to refresh it, to pick up newly published
    plugins.

modification points
======================

  • modify settings.mdo to allow <pluginGroups/> section which is a simple list
    of Strings.
  • create model file/project for manipulation and reading of plugins.xml files
  • modify the plugin upload (install?) process to modify the plugins.xml in the groupId directory

-> Look at the release plugin and RELEASE transformation for some ideas on how to do this.

  • create PluginGroupResolver to handle plugin-group mappings searches against same

I'll use this as a basis for implementing these changes. If you see any problems with this plan, please comment.

Show
John Casey added a comment - 21/Jun/05 11:29 AM I think I've got the issue condensed to the following: ---------------------------------- requirements ===============
  • allow users to specify a list of plugin groupId's to search
  • when a plugin is released (deployed?), a plugins.xml file under it's groupId should be modified to ensure that the plugin's information is provided.
  • a mapping prefix to plugin g:a will be constructed in memory using the user's search groups
  • default over to org.apache.maven.plugins if no matches are found, or if the search-groups are empty.
  • plugin.xml files can be cached locally, but an attempt should be made in all 'normal' cases (non-offline mode) to refresh it, to pick up newly published plugins.
modification points ======================
  • modify settings.mdo to allow <pluginGroups/> section which is a simple list of Strings.
  • create model file/project for manipulation and reading of plugins.xml files
  • modify the plugin upload (install?) process to modify the plugins.xml in the groupId directory
-> Look at the release plugin and RELEASE transformation for some ideas on how to do this.
  • create PluginGroupResolver to handle plugin-group mappings searches against same
I'll use this as a basis for implementing these changes. If you see any problems with this plan, please comment.
Hide
Permalink
John Casey added a comment - 21/Jun/05 11:30 AM

Forgot one point:

  • modify the lifecycle executor's prefix lookup method to use the PluginGroupResolver.
Show
John Casey added a comment - 21/Jun/05 11:30 AM Forgot one point:
  • modify the lifecycle executor's prefix lookup method to use the PluginGroupResolver.
Hide
Permalink
Brett Porter added a comment - 21/Jun/05 12:09 PM

looks good.

Show
Brett Porter added a comment - 21/Jun/05 12:09 PM looks good.
Hide
Permalink
John Casey added a comment - 21/Jun/05 6:51 PM

moving this one to beta-1, where we'll have time to get it right.

Show
John Casey added a comment - 21/Jun/05 6:51 PM moving this one to beta-1, where we'll have time to get it right.
Hide
Permalink
John Casey added a comment - 11/Jul/05 5:12 PM

tested with it0031.

Show
John Casey added a comment - 11/Jul/05 5:12 PM tested with it0031.
Hide
Permalink
Brett Porter added a comment - 18/Jul/05 6:29 PM

John is fixing up a couple of issues we've discussed

Show
Brett Porter added a comment - 18/Jul/05 6:29 PM John is fixing up a couple of issues we've discussed
Hide
Permalink
John Casey added a comment - 20/Jul/05 10:45 AM

1. plugins.xml is only re-resolved from the remote repository when:
a. it doesn't exist in the local repo
b. it doesn't contain the prefix that maven is currently looking for, and hasn't yet been refreshed during the current build session

2. installation of plugins.xml will not resolve against the remote repository, ever.
3. deployment of plugins.xml uses the distribution repository exclusively

Show
John Casey added a comment - 20/Jul/05 10:45 AM 1. plugins.xml is only re-resolved from the remote repository when: a. it doesn't exist in the local repo b. it doesn't contain the prefix that maven is currently looking for, and hasn't yet been refreshed during the current build session 2. installation of plugins.xml will not resolve against the remote repository, ever. 3. deployment of plugins.xml uses the distribution repository exclusively

People

  • Assignee:
    John Casey
    Reporter:
    Brett Porter
Vote (0)
Watch (1)

Dates

  • Created:
    10/May/05 12:39 AM
    Updated:
    01/Feb/06 2:42 PM
    Resolved:
    20/Jul/05 10:45 AM
  • Atlassian JIRA (v5.0.4#731-sha1:3aa7374)
  • Report a problem
  • Powered by a free Atlassian JIRA open source license for Codehaus. Try JIRA - bug tracking software for your team.