Uploaded image for project: 'Maven Deploy Plugin'
  1. Maven Deploy Plugin
  2. MDEPLOY-163

Maven Deploy Plugin Deploys Attached Sources A Second Time

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Won't Fix
    • 2.7
    • None
    • deploy:deploy-file
    • None
    • 64 Bit Linux

    Description

      This happens in a jar pom where I have attached sources to the jar thus:

      <plugin>
      	<groupId>org.apache.maven.plugins</groupId>
      	<artifactId>maven-source-plugin</artifactId>
      	<executions>
      		<execution>
      			<id>attach-sources-</id>
      			<phase>compile</phase>
      			<goals>
      				<goal>jar-no-fork</goal>
      			</goals>
      		</execution>
      	</executions>
      </plugin>
      

      When running the deploy phase this will result in the source jar being deployed to the repository (nexus in my case) in the normal fashion.

      I also had in the same pom (I've since moved it to another module to workaround this bug) deployment of additional configuration artifacts thus:

      <plugin>
      	<groupId>org.apache.maven.plugins</groupId>
      	<artifactId>maven-deploy-plugin</artifactId>
      	<executions>
      		<execution>
      			<id>deploy-REDACTED</id>
      			<phase>deploy</phase>
      			<configuration>
      				<groupId>REDACTED</groupId>
      				<artifactId>REDACTED</artifactId>
      				<version>${project.version}</version>
      				<file>REDACTED</file>
      				<packaging>xml</packaging>
      				<generatePom>true</generatePom>
      				<repositoryId>nexus</repositoryId>
      				<url>http://nexus:8081/content/repositories/${deployment.repository.suffix}</url>
      			</configuration>
      			<goals>
      				<goal>deploy-file</goal>
      			</goals>
      		</execution>
      	</executions>
      </plugin>
      

      When the deploy-file goal executes it will succeed to deploy the xml file but for some reason it is also attempting to upload the jar sources a second time.

      Attachments

        Activity

          People

            rfscholte Robert Scholte
            jonathon.golden Jonathon Golden
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: