You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Jack-Ziad Hawa <ja...@ericsson.com> on 2008/11/13 20:46:04 UTC

Error while executing "deploy" on imported maven project in Eclipse

Hello,

I am a bit new at this.

I have importe a maven project into Eclipse through: File>Import>Maven
Projects.
Then, in order to execute some maven goals, I right-clicked on the
project name in the navigator window, then I clicked on Run As and
executed the install and package goal and they worked successfully.

However, when I try to execute the "Deploy" goal, it gives me an error.

The following mojo encountered an error while executing:
Group-Id: org.apache.maven.plugins
Artifact-Id: maven-deploy-plugin
Version: 2.3
Mojo: deploy
brought in via: packaging: jar

While building project:
Group-Id: it.ericsson.mdp
Artifact-Id: EclipseTestJack
Version: 1.0.0-SNAPSHOT
>From file: C:\project\UserDetailsClient\pom.xml
Reason: Error retrieving previous build number for artifact
'it.ericsson.mdp:EclipseTestJack:jar': repository metadata for:
'snapshot it.ericsson.mdp:EclipseTestJack:1.0.0-SNAPSHOT' could not be
retrieved from repository: snapshots due to an error: Unsupported
Protocol: 'dav': Cannot find wagon which supports the requested
protocol: dav


I also would like to mention that in the Maven Console, there was a
problem in "red": 13/11/08 2:22:21 EST PM: Unable to update index for
central http://repo1.maven.org/maven2/
I figured it might be linked to the problem.

Any help is greatly appreciated.

Thank you,

Jack

RE: Error while executing "deploy" on imported maven project in Eclipse

Posted by Todd Thiessen <th...@nortel.com>.
I have noticed this as well. If you try and excute a project with
m2eclipse, you need to specify a wagon. However, if you run the same
command from the command line, a wagon seems to already be defined, ever
if you don't have one specified in your POM.  BTW, there are other
inconsistencies as well.

The best explanation I have heard for these inconsistences is the Maven
embedder is still a work in progress and IDEs use the embedder as an API
to maven.

If anyone could better explain these inconsistencies I would be happy to
hear it ;-).


---
Todd Thiessen

-----Original Message-----
From: Alexander Hachmann [mailto:public@thesofa.de] 
Sent: Friday, November 14, 2008 8:06 AM
To: Maven Users List
Subject: Re: Error while executing "deploy" on imported maven project in
Eclipse

Hi Jack,
when you want to deploy an artifact to the remote repositories such as
Archiva you will need to add an wagon extionsion to you build.
> I have importe a maven project into Eclipse through: File>Import>Maven

> Projects.
> Then, in order to execute some maven goals, I right-clicked on the 
> project name in the navigator window, then I clicked on Run As and 
> executed the install and package goal and they worked successfully.
>
> However, when I try to execute the "Deploy" goal, it gives me an
error.
>
> The following mojo encountered an error while executing:
> Group-Id: org.apache.maven.plugins
> Artifact-Id: maven-deploy-plugin
> Version: 2.3
> Mojo: deploy
> brought in via: packaging: jar
>
> While building project:
> Group-Id: it.ericsson.mdp
> Artifact-Id: EclipseTestJack
> Version: 1.0.0-SNAPSHOT
> From file: C:\project\UserDetailsClient\pom.xml
> Reason: Error retrieving previous build number for artifact
> 'it.ericsson.mdp:EclipseTestJack:jar': repository metadata for:
> 'snapshot it.ericsson.mdp:EclipseTestJack:1.0.0-SNAPSHOT' could not be

> retrieved from repository: snapshots due to an error: Unsupported
> Protocol: 'dav': Cannot find wagon which supports the requested
> protocol: dav
>
>   
It seems that you do not have the following snippet in your pom.xml's
build element.

        <!-- Webdav plugin needed to deploy file to repository -->
        <extensions>
            <extension>
                <groupId>org.apache.maven.wagon</groupId>
                <artifactId>wagon-webdav</artifactId>
                <version>1.0-beta-2</version>
            </extension>
        </extensions>

The Artifact will be sent via webdav to archiva or any other Maven
Proxy.

This might probably help you. And regard, that you will have to set
credentials whithin your settings for your snapshop repository aswell.

<servers>
    <server>
       <id>snapshots</id>
       <username>username</username>
       <password>*******</password>
    </server>
</servers>

Hope this helps.


Regards,
            Alex


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Error while executing "deploy" on imported maven project in Eclipse

Posted by Alexander Hachmann <pu...@thesofa.de>.
Hi Jack,
when you want to deploy an artifact to the remote repositories such as 
Archiva
you will need to add an wagon extionsion to you build.
> I have importe a maven project into Eclipse through: File>Import>Maven
> Projects.
> Then, in order to execute some maven goals, I right-clicked on the
> project name in the navigator window, then I clicked on Run As and
> executed the install and package goal and they worked successfully.
>
> However, when I try to execute the "Deploy" goal, it gives me an error.
>
> The following mojo encountered an error while executing:
> Group-Id: org.apache.maven.plugins
> Artifact-Id: maven-deploy-plugin
> Version: 2.3
> Mojo: deploy
> brought in via: packaging: jar
>
> While building project:
> Group-Id: it.ericsson.mdp
> Artifact-Id: EclipseTestJack
> Version: 1.0.0-SNAPSHOT
> From file: C:\project\UserDetailsClient\pom.xml
> Reason: Error retrieving previous build number for artifact
> 'it.ericsson.mdp:EclipseTestJack:jar': repository metadata for:
> 'snapshot it.ericsson.mdp:EclipseTestJack:1.0.0-SNAPSHOT' could not be
> retrieved from repository: snapshots due to an error: Unsupported
> Protocol: 'dav': Cannot find wagon which supports the requested
> protocol: dav
>
>   
It seems that you do not have the following snippet in your pom.xml's 
build element.

        <!-- Webdav plugin needed to deploy file to repository -->
        <extensions>
            <extension>
                <groupId>org.apache.maven.wagon</groupId>
                <artifactId>wagon-webdav</artifactId>
                <version>1.0-beta-2</version>
            </extension>
        </extensions>

The Artifact will be sent via webdav to archiva or any other Maven Proxy.

This might probably help you. And regard, that you will have to set 
credentials whithin your settings for your snapshop repository aswell.

<servers>
    <server>
       <id>snapshots</id>
       <username>username</username>
       <password>*******</password>
    </server>
</servers>

Hope this helps.


Regards,
            Alex


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org