我正在尝试使用命令 -mvn -Dhttps.protocols=TLSv1,TLSv1.1,TLSv1.2 install / mvn -Dhttps.protocols=TLSv1.2 install 在具有 java 1.7 的计算机中启用 TSLv1.2。但它抛出一些错误,说我的 pom.xml 有一些未解决的依赖项,这些依赖项错误之所以存在,是因为我的项目由于 TSLv1.2 问题而无法从 Maven 存储库下载。对我来说这似乎是一个僵局,有人能帮我解决这个问题吗?
我在Java 8中开发了一个项目,当我使用java 8开发项目时,我已经在maven中安装了ojdbc jar.现在我将项目转换为java 7.在这样做时,我面临着ojdbc.jar依赖性问题在pom.xml.它显示:
缺少神器com.oracle:ojdbc7:jar:12.1.0
在oracle依赖标记.当我尝试为ojdbc jar运行mvn install时,也会抛出错误.
[错误]无法在项目上执行目标SlotBookingAvailability:无法解析项目org.logicInfo.oms的依赖项:SlotBookingAvailability:war:0.0.1-SNAPSHOT:未能在https://repo.maven.a中找到com.oracle:ojdbc7:jar:12.1.0 .pache.org/ maven2被缓存在本地存储库中,在更新间隔之前不会重新尝试解析中心已经过去或强制更新.
的pom.xml
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>org.logicInfo.oms</groupId>
<artifactId>SlotBookingAvailability</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>war</packaging>
<name>SlotBookingAvailability</name>
<description>Demo project for Spring Boot</description>
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>1.5.9.RELEASE</version>
<relativePath/> <!-- lookup parent from repository -->
</parent>
<properties>
<start-class>org.logicInfo.oms.SlotBookingAvailability.SlotBookingAvailabilityApplication</start-class>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
<java.version>1.7</java.version>
</properties>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<dependency>
<groupId>com.oracle</groupId>
<artifactId>ojdbc7</artifactId>
<version>12.1.0</version>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-jdbc</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-devtools</artifactId>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-test</artifactId>
<scope>test</scope>
</dependency> …Run Code Online (Sandbox Code Playgroud)