[ http://jira.codehaus.org/browse/MNG-3119?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Paul Gier updated MNG-3119: --------------------------- Attachment: MNG-3119-maven-project-r558713.patch Adding a patch that displays a warning message if an attempt is made to attach a duplicate artifact. I didn't see any existing exception classes that fit this scenario, so I created a new exception class. The exception does not propagate any further than the MavenProjectHelper in this case because I didn't want to break any existing code (plugins, etc.) that may depend on the helper attach artifact methods not throwing an exception. > Duplicate attached artifacts should not be allowed. > --------------------------------------------------- > > Key: MNG-3119 > URL: http://jira.codehaus.org/browse/MNG-3119 > Project: Maven 2 > Issue Type: Improvement > Components: General > Affects Versions: 2.0.7 > Reporter: Paul Gier > Attachments: MNG-3119-maven-project-r558713.patch > > > Currently, a project allows duplicate artifacts to be attached. This causes > the second and other additional artifacts to overwrite the first attached > artifact. This occurs during the package, install, and deploy phases. > This can be reproduced by adding three instances of the source plugin (with > different ids) to a project build configuration. The 2nd plugin will > overwrite the first, and the third will overwrite the second. > The desired behaviour is that the user should receive a warning or error when > this happens. -- 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 - For more information on JIRA, see: http://www.atlassian.com/software/jira