【发布时间】:2020-08-04 09:42:22
【问题描述】:
[系统]
Spring Boot:2.1.7 发布
摇篮:4.10.2
我通常知道上面的错误是在端口号被其他程序使用的时候出现的,但是当我更改端口时也会出现这个错误。 正如预期的那样,错误是由在 Gradle 依赖项中添加的 Apache Poi 发生的。 我想知道解决这个问题的方法。 下面是我的 Gradle 代码。
buildscript {
ext {
springBootVersion = '2.1.7.RELEASE'
}
repositories {
mavenCentral()
jcenter()
}
dependencies {
classpath("org.springframework.boot:spring-boot-gradle-plugin:${springBootVersion}")
}
}
apply plugin: 'java'
apply plugin: 'eclipse'
apply plugin: 'org.springframework.boot'
apply plugin: 'io.spring.dependency-management'
group 'com.tistory.cafecoder'
version '1.0-SNAPSHOT'
sourceCompatibility = 1.8
repositories {
mavenCentral()
}
dependencies {
compile('org.springframework.boot:spring-boot-starter-web')
compile('org.projectlombok:lombok')
compile('org.springframework.boot:spring-boot-starter-data-jpa')
compile('com.h2database:h2')
compile('org.springframework.boot:spring-boot-starter-mustache')
compile('org.springframework.boot:spring-boot-starter-oauth2-client:')
compile('org.apache.poi:poi-ooxml:3.11')
compile('org.apache.commons:commons-io:1.3.2')
testCompile('org.springframework.boot:spring-boot-starter-test')
testCompile('org.springframework.security:spring-security-test')
}
【问题讨论】:
-
Apache POI 已添加您的依赖项与端口冲突无关
-
我觉得目前为止没有任何问题,而且我已经习惯性的关闭了服务器。由于添加Apache POI依赖后出现问题,想知道是不是这个问题。谢谢
标签: spring spring-boot gradle