You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by fy <fy...@gmail.cn> on 2006/12/26 08:34:01 UTC

About deploy:deploy-file

I creaded my remote repository in
10.10.100.22/app/opt/Apache2/htdocs/maven,and I can accessed it with
http://10.10.100.22/mavne. now I want put a jar into it .First I added the
following code in the settings.xml:
<server>
      <id>maven.repo</id>
      <username>maven</username>
      <password>mavne</password>
 </server>
then I used the cmd :

C:\Documents and Settings\Administrator\.m2\nfa\nfa\1.0.0>mvn -X
deploy:deploy-file -Dfile=nfa-1.0.0
.jar -Durl=http://10.10.100.22/mavne  -DrepositoryId=maven.repo 
-DgroupId=nfa -DartifactId=nfa -Dve
rsion=1.0.0 -Dpackaging=jar
+ Error stacktraces are turned on.
Maven version: 2.0.4
[DEBUG] Building Maven user-level plugin registry from: 'C:\Documents and
Settings\Administrator\.m2
\plugin-registry.xml'
[DEBUG] Building Maven global-level plugin registry from: 'C:\Program
Files\Apache Software Foundati
on\maven2\bin\..\conf\plugin-registry.xml'
[INFO] Scanning for projects...
[INFO] Searching repository for plugin with prefix: 'deploy'.
[DEBUG] maven-deploy-plugin: resolved to version 2.2.1 from repository
central
[DEBUG] Retrieving parent-POM: org.apache.maven.plugins:maven-plugins::1 for
project: null:maven-dep
loy-plugin:maven-plugin:2.2.1 from the repository.
[DEBUG] Retrieving parent-POM: org.apache.maven:maven-parent::1 for project:
org.apache.maven.plugin
s:maven-plugins:pom:1 from the repository.
[DEBUG] Retrieving parent-POM: org.apache:apache::1 for project:
org.apache.maven:maven-parent:pom:1
 from the repository.
[INFO]
----------------------------------------------------------------------------
[INFO] Building Maven Default Project
[INFO]    task-segment: [deploy:deploy-file] (aggregator-style)
[INFO]
----------------------------------------------------------------------------
[DEBUG]
org.apache.maven.plugins:maven-deploy-plugin:maven-plugin:2.2.1:runtime
(selected for runtim
e)
[DEBUG] Retrieving parent-POM: org.apache.maven:maven::2.0 for project:
org.apache.maven:maven-artif
act-manager:jar:2.0 from the repository.
[DEBUG]   org.apache.maven:maven-artifact-manager:jar:2.0:runtime (selected
for runtime)
[DEBUG]     org.codehaus.plexus:plexus-utils:jar:1.0.4:runtime (selected for
runtime)
[DEBUG]    
org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-8:runtime
(selected for runti
me)
[DEBUG]       classworlds:classworlds:jar:1.1-alpha-2:runtime (selected for
runtime)
[DEBUG]       junit:junit:jar:3.8.1:runtime (selected for runtime)
[DEBUG] Retrieving parent-POM: org.apache.maven:maven::2.0 for project:
org.apache.maven:maven-artif
act:jar:2.0 from the repository.
[DEBUG]     org.apache.maven:maven-artifact:jar:2.0:runtime (selected for
runtime)
[DEBUG] Retrieving parent-POM: org.apache.maven:maven::2.0 for project:
org.apache.maven:maven-repos
itory-metadata:jar:2.0 from the repository.
[DEBUG]     org.apache.maven:maven-repository-metadata:jar:2.0:runtime
(selected for runtime)
[DEBUG]    
org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-5:runtime (selected
for runtime)

[DEBUG] Retrieving parent-POM: org.apache.maven:maven::2.0 for project:
null:maven-project:jar:2.0 f
rom the repository.
[DEBUG]   org.apache.maven:maven-project:jar:2.0:runtime (selected for
runtime)
[DEBUG] Retrieving parent-POM: org.apache.maven:maven::2.0 for project:
org.apache.maven:maven-model
:jar:2.0 from the repository.
[DEBUG]     org.apache.maven:maven-model:jar:2.0:runtime (selected for
runtime)
[DEBUG] Retrieving parent-POM: org.apache.maven:maven::2.0 for project:
null:maven-profile:jar:2.0 f
rom the repository.
[DEBUG]     org.apache.maven:maven-profile:jar:2.0:runtime (selected for
runtime)
[DEBUG] Retrieving parent-POM: org.apache.maven:maven::2.0 for project:
org.apache.maven:maven-core:
jar:2.0 from the repository.
[DEBUG]   org.apache.maven:maven-core:jar:2.0:runtime (selected for runtime)
[DEBUG] Retrieving parent-POM: org.apache.maven:maven::2.0 for project:
null:maven-plugin-parameter-
documenter:jar:2.0 from the repository.
[DEBUG]    
org.apache.maven:maven-plugin-parameter-documenter:jar:2.0:runtime (selected
for runtime
)
[DEBUG] Retrieving parent-POM: org.apache.maven:maven::2.0 for project:
null:maven-error-diagnostics
:jar:2.0 from the repository.
[DEBUG]     org.apache.maven:maven-error-diagnostics:jar:2.0:runtime
(selected for runtime)
[DEBUG] Retrieving parent-POM: org.apache.maven:maven::2.0 for project:
org.apache.maven:maven-monit
or:jar:2.0 from the repository.
[DEBUG]     org.apache.maven:maven-monitor:jar:2.0:runtime (selected for
runtime)
[DEBUG]    
org.codehaus.plexus:plexus-interactivity-api:jar:1.0-alpha-4:runtime
(selected for runti
me)
[DEBUG] Retrieving parent-POM: org.apache.maven:maven::2.0 for project:
null:maven-settings:jar:2.0
from the repository.
[DEBUG]     org.apache.maven:maven-settings:jar:2.0:runtime (selected for
runtime)
[DEBUG]    
org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-5:runtime
(selected for runt
ime)
[DEBUG]     org.apache.maven.wagon:wagon-file:jar:1.0-alpha-5:runtime
(selected for runtime)
[DEBUG] Retrieving parent-POM: org.apache.maven:maven::2.0 for project:
org.apache.maven:maven-plugi
n-descriptor:jar:2.0 from the repository.
[DEBUG]     org.apache.maven:maven-plugin-descriptor:jar:2.0:runtime
(selected for runtime)
[DEBUG] Retrieving parent-POM: org.apache.maven:maven::2.0 for project:
org.apache.maven:maven-plugi
n-api:jar:2.0 from the repository.
[DEBUG]       org.apache.maven:maven-plugin-api:jar:2.0:runtime (selected
for runtime)
[DEBUG]     commons-cli:commons-cli:jar:1.0:runtime (selected for runtime)
[DEBUG]     org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-5:runtime
(selected for runtime)
[DEBUG]       com.jcraft:jsch:jar:0.1.23:runtime (selected for runtime)
[DEBUG] Retrieving parent-POM:
org.apache.maven.reporting:maven-reporting::2.0 for project: null:mav
en-reporting-api:jar:2.0 from the repository.
[DEBUG] Retrieving parent-POM: org.apache.maven:maven::2.0 for project:
org.apache.maven.reporting:m
aven-reporting:pom:2.0 from the repository.
[DEBUG]     org.apache.maven.reporting:maven-reporting-api:jar:2.0:runtime
(selected for runtime)
[DEBUG]       doxia:doxia-sink-api:jar:1.0-alpha-4:runtime (selected for
runtime)
[DEBUG]     org.apache.maven:maven-plugin-api:jar:2.0:runtime (selected for
runtime)
[DEBUG] Retrieving parent-POM: org.apache.maven:maven::2.0 for project:
org.apache.maven:maven-plugi
n-registry:jar:2.0 from the repository.
[DEBUG]     org.apache.maven:maven-plugin-registry:jar:2.0:runtime (selected
for runtime)
[DEBUG]   org.apache.maven:maven-plugin-api:jar:2.0:runtime (selected for
runtime)
[DEBUG]   org.apache.maven:maven-artifact:jar:2.0:runtime (selected for
runtime)
[DEBUG] Configuring mojo
'org.apache.maven.plugins:maven-deploy-plugin:2.2.1:deploy-file' -->
[DEBUG]   (f) artifactId = nfa
[DEBUG]   (f) file = C:\Documents and
Settings\Administrator\.m2\nfa\nfa\1.0.0\nfa-1.0.0.jar
[DEBUG]   (f) generatePom = true
[DEBUG]   (f) groupId = nfa
[DEBUG]   (s) localRepository = [local] -> file://C:\Documents and
Settings\Administrator\.m2\reposi
tory
[DEBUG]   (f) packaging = jar
[DEBUG]   (f) repositoryId = maven.repo
[DEBUG]   (f) repositoryLayout = default
[DEBUG]   (f) uniqueVersion = true
[DEBUG]   (f) url = http://10.10.100.22/mavne
[DEBUG]   (f) version = 1.0.0
[DEBUG] -- end configuration --
[INFO] [deploy:deploy-file]
[DEBUG] not adding permissions to wagon connection
Uploading: http://10.10.100.22/mavne/nfa/nfa/1.0.0/nfa-1.0.0.jar
96K uploaded
[INFO]
------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO]
------------------------------------------------------------------------
[INFO] Error deploying artifact: Unable to transfer file. HttpURLConnection
returned the response co
de: 502

[INFO]
------------------------------------------------------------------------
[DEBUG] Trace
org.apache.maven.lifecycle.LifecycleExecutionException: Error deploying
artifact: Unable to transfer
 file. HttpURLConnection returned the response code: 502
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor
.java:559)
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycl
eExecutor.java:488)
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.
java:458)
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultL
ifecycleExecutor.java:306)
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleE
xecutor.java:219)
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java
:140)
        at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:322)
        at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115)
        at org.apache.maven.cli.MavenCli.main(MavenCli.java:256)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at
org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
        at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
        at
org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
        at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.plugin.MojoExecutionException: Error deploying
artifact: Unable to trans
fer file. HttpURLConnection returned the response code: 502
        at
org.apache.maven.plugin.deploy.DeployFileMojo.execute(DeployFileMojo.java:240)
        at
org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:412)
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor
.java:534)
        ... 16 more
Caused by: org.apache.maven.artifact.deployer.ArtifactDeploymentException:
Error deploying artifact:
 Unable to transfer file. HttpURLConnection returned the response code: 502
        at
org.apache.maven.artifact.deployer.DefaultArtifactDeployer.deploy(DefaultArtifactDeployer
.java:91)
        at
org.apache.maven.plugin.deploy.DeployFileMojo.execute(DeployFileMojo.java:236)
        ... 18 more
Caused by: org.apache.maven.wagon.TransferFailedException: Unable to
transfer file. HttpURLConnectio
n returned the response code: 502
        at
org.apache.maven.wagon.providers.http.LightweightHttpWagon.put(LightweightHttpWagon.java:
143)
        at
org.apache.maven.artifact.manager.DefaultWagonManager.putRemoteFile(DefaultWagonManager.j
ava:180)
        at
org.apache.maven.artifact.manager.DefaultWagonManager.putArtifact(DefaultWagonManager.jav
a:109)
        at
org.apache.maven.artifact.deployer.DefaultArtifactDeployer.deploy(DefaultArtifactDeployer
.java:77)
        ... 19 more
[INFO]
------------------------------------------------------------------------
[INFO] Total time: 2 seconds
[INFO] Finished at: Tue Dec 26 15:19:45 CST 2006
[INFO] Final Memory: 2M/5M
[INFO]
------------------------------------------------------------------------

But I found the jar in  C:\Documents and
Settings\Administrator\.m2\repository . 
why? And what's wrong whit it?


-- 
View this message in context: http://www.nabble.com/About---deploy%3Adeploy-file-tf2881558s177.html#a8051587
Sent from the Maven - Users mailing list archive at Nabble.com.


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