2012-07-03 147 views
0

我有Tomcat的Maven的插件問題: 這裏的代碼Maven的阻塞下載jar文件(的artifactId:Tomcat的Maven的插件)

<plugin> 
    <groupId>org.codehaus.mojo</groupId> 
    <artifactId>tomcat-maven-plugin</artifactId> 
    <version>1.0-beta-1</version> 
</plugin> 

因此在運行此命令後:clean tomcat:run

我得到這個結果:

[INFO] Scanning for projects... 
[INFO]                   
[INFO] ------------------------------------------------------------------------ 
[INFO] Building seleniumproject Maven Webapp 0.0.1-SNAPSHOT 
[INFO] ------------------------------------------------------------------------ 
[INFO] 
[INFO] --- maven-clean-plugin:2.4.1:clean (default-clean) @ seleniumproject --- 
[INFO] Deleting C:\Users\Amira\junoWorkspace\seleniumproject\target 
[INFO] 
[INFO] >>> tomcat-maven-plugin:1.0-beta-1:run (default-cli) @ seleniumproject >>> 
[INFO] 
[INFO] --- maven-resources-plugin:2.5:resources (default-resources) @seleniumproject --- 
[debug] execute contextualize 
[WARNING] Using platform encoding (Cp1252 actually) to copy filtered resources, i.e. build is platform dependent! 
[INFO] Copying 0 resource 
[INFO] 
[INFO] --- maven-compiler-plugin:2.3.2:compile (default-compile) @ seleniumproject --- 
[INFO] No sources to compile 
[INFO] 
[INFO] <<< tomcat-maven-plugin:1.0-beta-1:run (default-cli) @ seleniumproject <<< 
[INFO] 
[INFO] --- tomcat-maven-plugin:1.0-beta-1:run (default-cli) @ seleniumproject --- 


Downloading: http://repo.maven.apache.org/maven2/org/apache/maven/maven-plugin- api/2.0/maven-plugin-api-2.0.pom 
Downloaded: http://repo.maven.apache.org/maven2/org/apache/maven/maven-plugin-api/2.0/maven-plugin-api-2.0.pom (601 B at 1.2 KB/sec) 
Downloading: http://repo.maven.apache.org/maven2/junit/junit/3.8.2/junit-3.8.2.pom 
....................................... 
Downloaded: http://repo.maven.apache.org/maven2/org/apache/tomcat/dbcp/6.0.16/dbcp-6.0.16.jar (194 KB at 128.6 KB/sec) 

Downloaded: http://repo.maven.apache.org/maven2/org/apache/tomcat/coyote/6.0.16/coyote-6.0.16.jar (725 KB at 367.5 KB/sec) 

正如你看到它在塊下載: 是否有解決方案請

+0

你是什麼意思的官方通過downloading''塊?也許有一個網絡問題。你可以再試一次嗎? – Raghuram

+0

我連接到互聯網,但它停止下載 –

回答

1

我不知道你來自哪裏得到的網址:

http://repo.maven.apache.org/maven2/ 

但看起來你已經在settings.xml文件更改了配置,導致Maven的中央有http://repo1.maven.apache.org/maven2/代替。此外,我可以推薦使用存儲庫管理器(Nexus,Archiva,Artifactory)。

BTW:你爲什麼要使用mojo.codehaus Tomcat插件,而不是Apache的http://tomcat.apache.org/maven-plugin.html

+0

'repo.maven.apache.org'是'repo1.maven.org'的同義詞。 – Raghuram

+0

我知道,但它表明settings.xml或pom文件發生了變化。 – khmarbaise