2016-09-01 2 views
1
와 오라클 jdbc7 드라이버를 가져 오려고하는

내가 받는다는으로 jdbc7 오라클 드라이버를 가져올 수 없습니다, 나는 튜토리얼 Oracle Blogs처럼 모든 것을했지만 나는 다음과 오류 접수 :오류 메이븐

Could not resolve dependencies for project com.jp:database_connection_app:jar:0.0.1: Failed to collect dependencies at com.oracle.jdbc:ojdbc7:jar:12.1.0.2: Failed to read artifact descriptor for com.oracle.jdbc:ojdbc7:jar:12.1.0.2: Could not transfer artifact com.oracle.jdbc:ojdbc7: pom:12.1.0.2 from/to maven.oracle.com (https://maven.oracle.com): unexpected end of stream on Connection{maven.oracle.com:443, proxy=HTTP @ /myProxyIP:myPort hostAddress=hostAddressIP cipherSuite=none protocol=http/1.1} (recycle count=0): \n not found: size=0 content=... ->

나에게 특별한 경우입니다 프록시 뒤에 있지만 settings.xml 파일을 이미 구성 했으므로 maven은 JDBC를 제외한 모든 종속성을 다운로드 할 수 있습니다. 나는 하이어되어야하는 정보를 이해하지 못했다 언급 한 튜토리얼에서는

...

<basicAuthScope> 
    <host>ANY </host> 
    <port>ANY </port> 
    <realm>OAM 11g </realm> 
</basicAuthScope> 

아마이 오류 소스입니다. 설정-security.xml이 설정의 동일한 경로에 생성됩니다

<dependencies> 
     <dependency> 
      <groupId>com.oracle.jdbc</groupId> 
      <artifactId>ojdbc7</artifactId> 
      <version>12.1.0.2</version> 
     </dependency> 
     <dependency> 
      <groupId>com.oracle.jdbc</groupId> 
      <artifactId>ucp</artifactId> 
      <version>12.1.0.2</version> 
     </dependency> 
    </dependencies> 

    <repositories> 
     <repository> 
      <id>maven.oracle.com</id> 
      <name>oracle-maven-repo</name> 
      <url>https://maven.oracle.com</url> 
      <layout>default</layout> 
      <releases> 
       <enabled>true</enabled> 
       <updatePolicy>always</updatePolicy> 
      </releases> 
     </repository> 
    </repositories> 

    <pluginRepositories> 
     <pluginRepository> 
      <id>maven.oracle.com</id> 
      <name>oracle-maven-repo</name> 
      <url>https://maven.oracle.com</url> 
      <layout>default</layout> 
      <releases> 
       <enabled>true</enabled> 
       <updatePolicy>always</updatePolicy> 
      </releases> 
     </pluginRepository> 
    </pluginRepositories> 

다음

내 Settings.XML이는 ... 여기

<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 
        https://maven.apache.org/xsd/settings-1.0.0.xsd"> 
<localRepository>${user.home}/.m2/repository</localRepository> 
<interactiveMode>true</interactiveMode> 
<usePluginRegistry>false</usePluginRegistry> 
<offline>false</offline> 
<pluginGroups/> 
<servers> 
    <server> 
     <id>maven.oracle.com</id> 
     <username>myUsername</username> 
     <password>My_Encripted_Password</password> 
     <configuration> 
     <basicAuthScope> 
      <host>ANY</host> 
      <port>ANY</port> 
      <realm>OAM 11g</realm> 
     </basicAuthScope> 
    <httpConfiguration> 
     <all> 
     <params> 
     <property> 
      <name>http.protocol.allow-circular-redirects</name> 
      <value>%b,true</value> 
     </property> 
     </params> 
     </all> 
    </httpConfiguration> 
     </configuration> 
    </server> 
</servers> 
<mirrors> 
    <mirror> 
     <id>UK</id> 
     <name>UK Central</name> 
     <url>http://uk.maven.org/maven2</url> 
     <mirrorOf>central</mirrorOf> 
    </mirror> 
</mirrors> 
<proxies> 
    <proxy> 
     <id>default</id> 
     <active>true</active> 
     <protocol>http</protocol> 
     <host>myProxy</host> 
     <port>myPort</port> 
     <username>myUsername</username> 
     <password>myPassword</password> 
     <nonProxyHosts>*.google.com</nonProxyHosts> 
    </proxy> 
</proxies> 
<profiles/> 
<activeProfiles/> 
</settings> 

내 POM은 .... xxx

도움 주셔서 감사합니다.

+0

안에있는 모든 것을 사용하지 마십시오. 설정 파일 –

+0

pom.xml에? server.xml? [최소한의 완전하고 검증 가능한 예제를 만드는 방법] –

+0

실례합니다. 나는 settings.xml과 pom으로 질문을 편집했다. – Jesus

답변

2

내가 원하는 것 같은 라이브러리를 가져올 수는, 나는 다른 솔루션을 검색했다 :

  1. Oracle Web Site
  2. 는 로컬 저장소를 받는다는하기 위해 항아리를 포함에서 항아리를 다운로드합니다. 사람이 다른 생각이있는 경우 종속성과 Mkyong Web Site
  3. 업데이트 응원단에서 배운 것은

, 나는 알고 드릴 것입니다.