Maven Install Plugin
  1. Maven Install Plugin
  2. MINSTALL-76

Maven-Install-Plugin installs an attached artifact twice if no primary artifact exists

    Details

    • Type: Bug Bug
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Not A Bug
    • Affects Version/s: 2.2, 2.3
    • Fix Version/s: None
    • Component/s: install:install
    • Labels:
      None
    • Number of attachments :
      0

      Description

      I've noticed that both the maven install plugin and maven deploy plugin installs/deploys the attached artifacts twice if the primary artifact does not exist.

      [DEBUG] Configuring mojo 'org.apache.maven.plugins:maven-install-plugin:2.3:install' -->
      [DEBUG]   (f) artifact = com.mycompany.banking.project:Process:jar:2.4-SNAPSHOT
      [DEBUG]   (f) attachedArtifacts = [com.mycompany.banking.project:Process:jar:xpdl:2.4-SNAPSHOT, com.mycompany.banking.project:Process:jar:xpdl:2.4-SNAPSHOT]
      [DEBUG]   (f) createChecksum = false
      [DEBUG]   (f) localRepository = Repository[local|file://C:\Documents and Settings\John.Doe\.m2\repository]
      [DEBUG]   (f) packaging = jar
      [DEBUG]   (f) pomFile = C:\Workspaces\project\Process\pom.xml
      [DEBUG]   (f) updateReleaseInfo = false
      [DEBUG] -- end configuration --
      [INFO] [install:install {execution: default-install}]
      [INFO] No primary artifact to install, installing attached artifacts instead.
      [INFO] Installing C:\Workspaces\project\Process\pom.xml to C:\Documents and Settings\John.Doe\.m2\repository\com\mycompany\banking\project\Process\2.4-SNAPSHOT\Process-2.4-SNAPSHOT.pom
      [INFO] Installing C:\Workspaces\project\Process\target\Process-2.4-SNAPSHOT-xpdl.jar to C:\Documents and Settings\John.Doe\.m2\repository\com\sungard\banking\project\Process\2.4-SNAPSHOT\Process-2.4-SNAPSHOT-xpdl.jar
      [INFO] Installing C:\Workspaces\project\Process\target\Process-2.4-SNAPSHOT-xpdl.jar to C:\Documents and Settings\John.Doe\.m2\repository\com\sungard\banking\project\Process\2.4-SNAPSHOT\Process-2.4-SNAPSHOT-xpdl.jar
      

        Activity

        Hide
        David Williams added a comment -

        Not sure what the root issue is. It looks like the jar plugin is running twice as well. I'm using Maven 2.2.1

        Show
        David Williams added a comment - Not sure what the root issue is. It looks like the jar plugin is running twice as well. I'm using Maven 2.2.1
        Hide
        David Williams added a comment -

        I think I have found the issue. I'll confirm and cancel this defect if my hunch is correct.

        Show
        David Williams added a comment - I think I have found the issue. I'll confirm and cancel this defect if my hunch is correct.
        Hide
        Benjamin Bentmann added a comment -

        [DEBUG] (f) attachedArtifacts = [com.mycompany.banking.project:Process:jar:xpdl:2.4-SNAPSHOT, com.mycompany.banking.project:Process:jar:xpdl:2.4-SNAPSHOT]

        The artifact is attached/created two times, so this is either a bug in the plugin attaching those artifacts or just a misconfiguraton in the POM.

        Show
        Benjamin Bentmann added a comment - [DEBUG] (f) attachedArtifacts = [com.mycompany.banking.project:Process:jar:xpdl:2.4-SNAPSHOT, com.mycompany.banking.project:Process:jar:xpdl:2.4-SNAPSHOT] The artifact is attached/created two times, so this is either a bug in the plugin attaching those artifacts or just a misconfiguraton in the POM.
        Hide
        David Williams added a comment -

        Thanks Benjamin. It turns out it was a misconfiguration in the maven-jar-plugin. I confirmed late last night and was going to close this ticket today. Thanks, David

        Show
        David Williams added a comment - Thanks Benjamin. It turns out it was a misconfiguration in the maven-jar-plugin. I confirmed late last night and was going to close this ticket today. Thanks, David

          People

          • Assignee:
            Benjamin Bentmann
            Reporter:
            David Williams
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: