学习框架之前必须要了解版本,这是你学习的前提,如果不了解版本,后面出了莫名其妙的错误你会抓狂。
所以学习springcloud之前我们看看他们对应的版本关系。
关于maven仓库的版本列表
spring-cloud-dependencies 版本列表可查看:
https://mvnrepository.com/artifact/org.springframework.cloud/spring-cloud-dependencies
spring-boot-starter-parent 版本列表可查看:
https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-parent
如何查看springboot对应的springcloud版本呢?
进入spingboot官网:https://spring.io/projects/spring-boot
查看当前springboot版本:
查看所对应springcloud版本:
版本对应关系
大版本对应:
Spring Cloud | Spring Boot |
---|---|
Angel版本 | 兼容Spring Boot 1.2.x |
Brixton版本 | 兼容Spring Boot 1.3.x,也兼容Spring Boot 1.4.x |
Camden版本 | 兼容Spring Boot 1.4.x,也兼容Spring Boot 1.5.x |
Dalston版本、Edgware版本 | 兼容Spring Boot 1.5.x,不兼容Spring Boot 2.0.x |
Finchley版本 | 兼容Spring Boot 2.0.x,不兼容Spring Boot 1.5.x |
Greenwich版本 | 兼容Spring Boot 2.1.x |
在实际开发过程中,我们需要更详细的版本对应:
Spring Boot | Spring Cloud |
---|---|
1.5.2.RELEASE | Dalston.RC1 |
1.5.9.RELEASE | Edgware.RELEASE |
2.0.2.RELEASE | Finchley.BUILD-SNAPSHOT |
2.0.3.RELEASE | Finchley.RELEASE |
具体版本你们可以自己去查阅maven仓库,或者搜索资料。
看完springboot与springcloud版本我们接下来看看 springcloud中一些组件相关版本的依赖关系:
首先如果需要自己查看关系可以到maven仓库中查看如下图:
我们先看看 springcloud中:
Dalston版本、Edgware版本
D版本和E版本的区别
二者均基于SpringBoot的1.5.x版本。但支持其他组件的版本不同,如以 Dalston.SR4 和 Edgware.RELEASE 来对比:
spring-cloud-config 分别对应 1.3.3和 1.4.0;
spring-cloud-netflix 分别对应 1.3.5和 1.4.0;
spring-cloud-consul 分别对应 1.2.1和 1.3.0;
spring-cloud-gateway 前者不支持,后者 1.0.0。
每个小版本的不同,会有细微差别。
所以看到这里,去网上搜集文章的时候,如果没有讲述版本,一律不要看。
做技术最难能可贵的就是持续的学习,吸收知识,不断的思考形成自己的理解和模式。
如果你的理念相同,可以加群一起聊聊:600922504