简体   繁体   English

未找到依赖项 'org.springframework.boot:spring-boot-starter-web:2.3.0.RELEASE'

[英]Dependency 'org.springframework.boot:spring-boot-starter-web:2.3.0.RELEASE' not found

I am having a problem while creating a simple spring boot web application.我在创建一个简单的spring boot web 应用程序时遇到问题。 I am building this app using Intellij Idea IDE.我正在使用 Intellij Idea IDE 构建这个应用程序。 There is a issue arising related to the dependency.出现了与依赖相关的问题。 Intellij is saying - Dependency 'org.springframework.boot:spring-boot-starter-web:2.3.0.RELEASE' not found (in pom.xml ). Intellij 说 - Dependency 'org.springframework.boot:spring-boot-starter-web:2.3.0.RELEASE' not found (在pom.xml中)。

Detailed Error Information:详细错误信息:

Dependency 'org.springframework.boot:spring-boot-starter-web:2.3.0.RELEASE' not found.
Tag name: artifactId Description : The unique id for an artifact produced by the project group, e.g. maven-artifact. Version : 3.0.0+ 
<?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 https://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <parent>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-parent</artifactId>
        <version>2.3.0.RELEASE</version>
        <relativePath/> <!-- lookup parent from repository -->
    </parent>
    <groupId>com.example</groupId>
    <artifactId>springboot-demo</artifactId>
    <version>0.0.1-SNAPSHOT</version>
    <name>springboot-demo</name>
    <description>Demo project for Spring Boot</description>

    <properties>
        <java.version>1.8</java.version>
    </properties>

    <dependencies>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-web</artifactId>
        </dependency>

        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-test</artifactId>
            <scope>test</scope>
            <exclusions>
                <exclusion>
                    <groupId>org.junit.vintage</groupId>
                    <artifactId>junit-vintage-engine</artifactId>
                </exclusion>
            </exclusions>
        </dependency>
    </dependencies>

    <build>
        <plugins>
            <plugin>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-maven-plugin</artifactId>
            </plugin>
        </plugins>
    </build>

</project>

I had a similar issue.我有一个类似的问题。 Easiest fix is to Invalidate Caches and Restart最简单的解决方法是使缓存无效并重新启动

IntelliJ Idea 使缓存无效并重新启动

Maven will then re-sync your POM file after the restart. Maven 将在重启后重新同步您的 POM 文件。 No need to make changes anywhere else.无需在其他任何地方进行更改。

Spring Boot 2.3.0.RELEASE

If invalidate Caches / Restart... doesn't work, check Always update snapshots from "File -> Settings -> Building, Execution, Deployment -> Build Tools -> Maven".如果无效Caches / Restart...不起作用,请检查Always update snapshots For me worked like a charm.对我来说,工作就像一个魅力。

I was having the exact same problem then I found a way to overcome that.我遇到了完全相同的问题,然后我找到了克服它的方法。 I am not an expert on Spring Boot so I don't know what causes this but I can help you to fix.我不是 Spring 引导方面的专家,所以我不知道是什么原因造成的,但我可以帮你解决。 Go to https://start.spring.io/ then Click on the add dependencies on the top right corner of the pic. Go 到https://start.spring.io/然后点击图片右上角的添加依赖项。 after that select Spring Web under the dropdown menu, then generate the initializr again.之后在下拉菜单下的 select Spring Web ,然后再次生成初始化程序。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 “依赖&#39;org.springframework.boot:spring-boot-starter-log4j2:2.3.5.RELEASE&#39;未找到” - "Dependency 'org.springframework.boot:spring-boot-starter-log4j2:2.3.5.RELEASE' not found " 未找到依赖项 'org.springframework.boot:spring-boot-starter-security:2.2.6.RELEASE' - Dependency 'org.springframework.boot:spring-boot-starter-security:2.2.6.RELEASE' not found 未找到依赖项 &#39;org.springframework.boot:spring-boot-starter-validation:2.5.1&#39; - Dependency 'org.springframework.boot:spring-boot-starter-validation:2.5.1' not found 未找到依赖项 &#39;org.springframework.boot:spring-boot-starter-data-jpa:2.5.3&#39; - Dependency 'org.springframework.boot:spring-boot-starter-data-jpa:2.5.3' not found 找不到 org.springframework.boot:spring-boot-starter-parent:2.4.9.RELEASE - Could not find org.springframework.boot:spring-boot-starter-parent:2.4.9.RELEASE org.springframework.boot:spring-boot-starter-parent:2.4.0' 未找到 - org.springframework.boot:spring-boot-starter-parent:2.4.0' not found 项目 'org.springframework.boot:spring-boot-starter-parent:2.4.0' 未找到 - Project 'org.springframework.boot:spring-boot-starter-parent:2.4.0' not found 无法传输工件 org.springframework.boot:spring-boot-starter-parent:pom - Could not transfer artifact org.springframework.boot:spring-boot-starter-parent:pom 无法解析 org.springframework.boot:spring-boot-starter-thymeleaf - Unable to resolve org.springframework.boot:spring-boot-starter-thymeleaf 找不到ID为&#39;org.springframework.boot&#39;的插件 - plugin with id 'org.springframework.boot' not found
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM