2016-02-18 43 views
2

雖然使用Maven錯誤:無法檢索javax.sql中:JDBC-stdext-2.0

下載JCS
<dependency> 
    <groupId>jcs</groupId> 
    <artifactId>jcs</artifactId> 
    <version>1.3</version> 
</dependency> 

錯誤:

[WARNING] An error occurred during dependency resolution. 
    Failed to retrieve javax.sql:jdbc-stdext-2.0 
Caused by: Failure to find javax.sql:jdbc-stdext:jar:2.0 in http://repo.maven.apache.org/maven2 was cached in the local repository, resolution will not be reattempted until the upd 
ate interval of central has elapsed or updates are forced 
Try downloading the file manually from: 
    http://java.sun.com/products/jdbc/download.html 
Then, install it using the command: 
    mvn install:install-file -DgroupId=javax.sql -DartifactId=jdbc-stdext -Dversion=2.0 -Dpackaging=jar -Dfile=/path/to/file 
Alternatively, if you host your own repository you can deploy the file there: 
    mvn deploy:deploy-file -DgroupId=javax.sql -DartifactId=jdbc-stdext -Dversion=2.0 -Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id] 
Path to dependency: 
     1) com.samsung.jcs:jcs_demo:jar:1.0-SNAPSHOT 
     2) jcs:jcs:jar:1.3 
     3) mysql:mysql-connector-java:jar:3.0.10 
     4) javax.sql:jdbc-stdext:jar:2.0 
    javax.sql:jdbc-stdext:jar:2.0 
from the specified remote repositories: 
    central (http://repo.maven.apache.org/maven2, releases=true, snapshots=false) 
[INFO] Unable to read jar manifest from C:\Users\arun.km\.m2\repository\javax\sql\jdbc-stdext\2.0\jdbc-stdext-2.0.jar 

同樣 無法檢索的javax。交易:jta-1.0.1B

+1

對此有幫助嗎? http://stackoverflow.com/q/33075830/4290096 –

+0

我的pom文件中沒有排除。 jcs.jar的正確組ID解決了這個問題。 – Arun

+0

所以你的問題解決了?然後你可以添加它作爲答案。 –

回答

1

解決方案使用新的Grounp:org.apache.jcs

<dependency> 
    <groupId>org.apache.jcs</groupId> 
    <artifactId>jcs</artifactId> 
    <version>1.3</version> 
</dependency>