首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >找不到依赖'org.springframework.boot:spring-boot-starter-security:2.2.6.RELEASE‘

找不到依赖'org.springframework.boot:spring-boot-starter-security:2.2.6.RELEASE‘
EN

Stack Overflow用户
提问于 2020-05-01 05:43:05
回答 5查看 7.2K关注 0票数 0

我是春天的新手,所以如果你们中的任何人能在这方面帮助我,我将非常感激。我使用当前版本的2.2.6添加了spring启动程序安全性的依赖项,我的父版本也有相同的版本。但还是出了点差错-

'org.springframework.boot:spring-boot-starter-security:2.2.6.RELEASE‘

Dependency未找到.Tag名称: artifactId描述:项目组生成的工件的唯一id,例如maven-.Tag。版本: 3.0.0+ *

**事先为任何错误道歉!**

代码语言:javascript
运行
复制
<?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.2.6.RELEASE</version>
        <relativePath/> <!-- lookup parent from repository -->
    </parent>
    <groupId>com.arpita</groupId>
    <artifactId>security_first</artifactId>
    <version>0.0.1-SNAPSHOT</version>
    <name>security_first</name>
    <description>Demo project for Spring Boot</description>

    <properties>
        <java.version>11</java.version>
    </properties>

    <dependencies>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-web</artifactId>
        </dependency>
        <!-- https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-security -->
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-security</artifactId>
            <version>2.2.6.RELEASE</version>
        </dependency>
EN

回答 5

Stack Overflow用户

发布于 2020-10-25 07:24:16

文件->使缓存/重新启动无效,它将工作。

票数 5
EN

Stack Overflow用户

发布于 2020-05-01 08:22:31

顺便说一句,您不需要为初学者POM指定版本。如果您从安全启动器中删除版本标记,它应该可以正常工作。

票数 2
EN

Stack Overflow用户

发布于 2020-05-01 11:19:10

您不需要提到spring引导项目的版本,它将在spring引导之前负责,添加下面的依赖项

代码语言:javascript
运行
复制
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-security</artifactId>
</dependency>

最后,更新项目。

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/61537415

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档