Spring Boot starter reactor netty 依赖错误

问题描述

我正在学习构建 Spring Boot Websocket Application 的教程。但是,在为 Reactor Netty 添加依赖项后,出现依赖项错误。我试过重新加载项目也无济于事。我是 Reactor Netty 的新手,所以我不太了解它,我是否还需要其他依赖项。

这是我在 pom.xml 中的依赖项:

<dependencies>
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-websocket</artifactId>
    </dependency>
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-reactor-netty</artifactId>
    </dependency>
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-test</artifactId>
        <scope>test</scope>
    </dependency>
</dependencies>

这是错误

Cannot resolve jakarta.annotation:jakarta.annotation-api:1.3.5
Cannot resolve org.ow2.asm:asm:9.1
Cannot resolve jakarta.xml.bind:jakarta.xml.bind-api:2.3.3
Cannot resolve org.junit.platform:junit-platform-engine:1.7.2
Cannot resolve org.springframework.boot:spring-boot-starter-websocket:2.5.1
Cannot resolve org.springframework:spring-websocket:5.3.8
Cannot resolve org.apache.logging.log4j:log4j-to-slf4j:2.14.1
Cannot resolve org.junit.jupiter:junit-jupiter-params:5.7.2
Cannot resolve org.springframework.boot:spring-boot-test-autoconfigure:2.5.1
Cannot resolve org.springframework.boot:spring-boot-starter-logging:2.5.1
Cannot resolve org.springframework:spring-messaging:5.3.8
Cannot resolve org.apache.tomcat.embed:tomcat-embed-websocket:9.0.46
Cannot resolve org.opentest4j:opentest4j:1.2.0
Cannot resolve org.slf4j:slf4j-api:1.7.30
Cannot resolve com.fasterxml.jackson.datatype:jackson-datatype-jdk8:2.12.3
Cannot resolve net.minidev:accessors-smart:2.4.7
Cannot resolve ch.qos.logback:logback-core:1.2.3
Cannot resolve org.springframework.boot:spring-boot-starter-json:2.5.1
Cannot resolve org.springframework:spring-web:5.3.8
Cannot resolve org.springframework.boot:spring-boot-starter-tomcat:2.5.1
Cannot resolve org.skyscreamer:jsonassert:1.5.0
Cannot resolve org.assertj:assertj-core:3.19.0
Cannot resolve org.springframework.boot:spring-boot:2.5.1
Cannot resolve com.fasterxml.jackson.datatype:jackson-datatype-jsr310:2.12.3
Cannot resolve com.fasterxml.jackson.module:jackson-module-parameter-names:2.12.3
Cannot resolve net.bytebuddy:byte-buddy-agent:1.10.22
Cannot resolve com.vaadin.external.google:android-json:0.0.20131108.vaadin1
Cannot resolve org.springframework.boot:spring-boot-starter:2.5.1
Cannot resolve org.xmlunit:xmlunit-core:2.8.2
Cannot resolve org.springframework.boot:spring-boot-starter-web:2.5.1
Cannot resolve com.jayway.jsonpath:json-path:2.5.0
Cannot resolve org.slf4j:jul-to-slf4j:1.7.30
Cannot resolve org.springframework:spring-beans:5.3.8
Cannot resolve org.apache.logging.log4j:log4j-api:2.14.1
Cannot resolve org.springframework:spring-jcl:5.3.8
Cannot resolve net.minidev:json-smart:2.4.7
Cannot resolve com.fasterxml.jackson.core:jackson-annotations:2.12.3
Cannot resolve org.springframework.boot:spring-boot-autoconfigure:2.5.1
Cannot resolve org.springframework:spring-core:5.3.8
Cannot resolve com.fasterxml.jackson.core:jackson-core:2.12.3
Cannot resolve org.apache.tomcat.embed:tomcat-embed-core:9.0.46
Cannot resolve org.yaml:snakeyaml:1.28
Cannot resolve org.springframework:spring-test:5.3.8
Cannot resolve org.junit.jupiter:junit-jupiter-api:5.7.2
Cannot resolve net.bytebuddy:byte-buddy:1.10.22
Cannot resolve org.objenesis:objenesis:3.2
Cannot resolve org.springframework:spring-webmvc:5.3.8
Cannot resolve com.fasterxml.jackson.core:jackson-databind:2.12.3
Cannot resolve org.springframework.boot:spring-boot-test:2.5.1
Cannot resolve org.springframework:spring-context:5.3.8
Cannot resolve org.junit.jupiter:junit-jupiter:5.7.2
Cannot resolve org.apache.tomcat.embed:tomcat-embed-el:9.0.46
Cannot resolve org.mockito:mockito-core:3.9.0
Cannot resolve jakarta.activation:jakarta.activation-api:1.2.2
Cannot resolve org.springframework:spring-expression:5.3.8
Cannot resolve org.springframework:spring-aop:5.3.8
Cannot resolve org.mockito:mockito-junit-jupiter:3.9.0
Cannot resolve org.apiguardian:apiguardian-api:1.1.0
Cannot resolve org.junit.jupiter:junit-jupiter-engine:5.7.2
Cannot resolve org.junit.platform:junit-platform-commons:1.7.2
Cannot resolve org.springframework.boot:spring-boot-starter-reactor-netty:2.5.1
Cannot resolve org.springframework.boot:spring-boot-starter-test:2.5.1
Cannot resolve org.hamcrest:hamcrest:2.2
Cannot resolve ch.qos.logback:logback-classic:1.2.3

感谢您阅读这个问题。

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)