【Springboot】spring-boot-starter-redis包报错 :unknown

springboot集成redis时,引入spring-boot-starter-redis包报错,maven找不到这个资源.如下图:

我的项目中,spring boot是 用的2.0.4版本.spring-boot-starter-redis在springboot 1.4.7版本后,改为了spring-boot-starter-data-redis,

所以如果想集成redis,应该引用spring-boot-starter-data-redis.

如果就是想用前者,那么就应该加上版本号.

 
      

 <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-redis</artifactId>
        <version>1.4.7.RELEASE</version>
 </dependency>
posted on 2019-12-22 13:05  小破孩楼主  阅读(2791)  评论(0编辑  收藏  举报