Spring Cloud provides tools for developers to quickly build some of the common patterns in distributed systems (e.g. configuration management, service discovery, circuit breakers, intelligent routing, micro-proxy, control bus, one-time tokens, global locks, leadership election, distributed sessions, cluster state). Coordination of distributed systems leads to boiler plate patterns, and using Spring Cloud developers can quickly stand up services and applications that implement those patterns. They will work well in any distributed environment, including the developer’s own laptop, bare metal data centres, and managed platforms such as Cloud Foundry.

Spring Cloud为开发人员提供了工具,以快速构建分布式系统中的一些常见模式(例如,配置管理,服务发现,断路器,智能路由,微代理,控制总线,一次性令牌,全局锁,领导选举,分布式会话,群集状态)。分布式系统的协调导致样板式样,并且使用Spring Cloud开发人员可以快速站起来实现这些样板的服务和应用程序。它们将在任何分布式环境中都能很好地工作,包括开发人员自己的笔记本电脑,裸机数据中心以及诸如Cloud Foundry之类的托管平台.

特性

  • 分布式/版本化配置
  • 服务注册和发现
  • 路由
  • 服务与服务间的调用
  • 负载均衡
  • 断路器
  • 全局锁
  • 领导选举与集群状态
  • 分布式消息传递

1、Spring Cloud版本选择

1、版本关系

Spring Cloud 采用了英国伦敦地铁站的名称来命名,并由地铁站名称字母A-Z依次类推的形式来发布迭代版本

SpringCloud是一个由许多子项目组成的综合项目,各子项目有不同的发布节奏。为了管理SpringCloud与各子项目的版本依赖关系,发布了一个清单,其中包括了某个SpringCloud版本对应的子项目版本。为了避免SpringCloud版本号与子项目版本号混淆,SpringCloud版本采用了名称而非版本号的命名,这些版本的名字采用了伦敦地铁站的名字,根据字母表的顺序来对应版本时间顺序。例如Angel是第一个版本, Brixton是第二个版本。

当SpringCloud的发布内容积累到临界点或者一个重大BUG被解决后,会发布一个"service releases"版本,简称SRX版本,比如Greenwich.SR2就是SpringCloud发布的Greenwich版本的第2个SRX版本。

2、Spring Cloud与Spring Boot依赖关系

官方:https://spring.io/projects/spring-cloud#overview

[外链图片转存失败,源站可能有防盗链机制,建议将图片保存下来直接上传(img-iFAmarcY-1668319981604)(SpringCloud学习笔记.assets/image-20210413115522096.png)]

更详细版本对应的查看:https://start.spring.io/actuator/info

json格式化:截止(2021.04.13)

{
"git": {
"branch": "709ff1cec88a124ef588f6185e5dc237766f3236",
"commit": {
"id": "709ff1c",
"time": "2021-04-10T08:56:10Z"
}
},
"build": {
"version": "0.0.1-SNAPSHOT",
"artifact": "start-site",
"versions": {
"spring-boot": "2.4.4",
"initializr": "0.11.0-SNAPSHOT"
},
"name": "start.spring.io website",
"time": "2021-04-12T11:22:19.209Z",
"group": "io.spring.start"
},
"bom-ranges": {
"azure": {
"2.2.4": "Spring Boot >=2.2.0.RELEASE and <2.3.0.M1",
"3.2.0": "Spring Boot >=2.3.0.M1 and <2.4.0-M1",
"3.3.0": "Spring Boot >=2.4.0.M1 and <2.5.0-M1"
},
"codecentric-spring-boot-admin": {
"2.2.4": "Spring Boot >=2.2.0.RELEASE and <2.3.0.M1",
"2.3.1": "Spring Boot >=2.3.0.M1 and <2.5.0-M1"
},
"solace-spring-boot": {
"1.0.0": "Spring Boot >=2.2.0.RELEASE and <2.3.0.M1",
"1.1.0": "Spring Boot >=2.3.0.M1 and <2.5.0-M1"
},
"solace-spring-cloud": {
"1.0.0": "Spring Boot >=2.2.0.RELEASE and <2.3.0.M1",
"1.1.1": "Spring Boot >=2.3.0.M1 and <2.4.0-M1",
"2.0.0": "Spring Boot >=2.4.0.M1 and <2.5.0-M1"
},
"spring-cloud": {
"Hoxton.SR10": "Spring Boot >=2.2.0.RELEASE and <2.3.10.BUILD-SNAPSHOT",
"Hoxton.BUILD-SNAPSHOT": "Spring Boot >=2.3.10.BUILD-SNAPSHOT and <2.4.0.M1",
"2020.0.0-M3": "Spring Boot >=2.4.0.M1 and <=2.4.0.M1",
"2020.0.0-M4": "Spring Boot >=2.4.0.M2 and <=2.4.0-M3",
"2020.0.0": "Spring Boot >=2.4.0.M4 and <=2.4.0",
"2020.0.2": "Spring Boot >=2.4.1 and <2.5.0-M1",
"2020.0.3-SNAPSHOT": "Spring Boot >=2.4.5-SNAPSHOT"
},
"spring-cloud-alibaba": {
"2.2.1.RELEASE": "Spring Boot >=2.2.0.RELEASE and <2.3.0.M1"
},
"spring-cloud-gcp": {
"2.0.0": "Spring Boot >=2.4.0-M1 and <2.5.0-M1"
},
"spring-cloud-services": {
"2.2.6.RELEASE": "Spring Boot >=2.2.0.RELEASE and <2.3.0.RELEASE",
"2.3.0.RELEASE": "Spring Boot >=2.3.0.RELEASE and <2.4.0-M1",
"2.4.1": "Spring Boot >=2.4.0-M1 and <2.5.0-M1"
},
"spring-geode": {
"1.2.12.RELEASE": "Spring Boot >=2.2.0.RELEASE and <2.3.0.M1",
"1.3.9.RELEASE": "Spring Boot >=2.3.0.M1 and <2.4.0-M1",
"1.4.4": "Spring Boot >=2.4.0-M1 and <2.5.0-M1",
"1.5.0-M3": "Spring Boot >=2.5.0-M1"
},
"vaadin": {
"14.5.2": "Spring Boot >=2.1.0.RELEASE and <2.5.0-M1"
},
"wavefront": {
"2.0.2": "Spring Boot >=2.1.0.RELEASE and <2.4.0-M1",
"2.1.0": "Spring Boot >=2.4.0-M1"
}
},
"dependency-ranges": {
"native": {
"0.9.0": "Spring Boot >=2.4.3 and <2.4.4",
"0.9.1": "Spring Boot >=2.4.4 and <2.4.5-SNAPSHOT",
"0.9.2-SNAPSHOT": "Spring Boot >=2.4.5-SNAPSHOT and <2.5.0-M1"
},
"okta": {
"1.4.0": "Spring Boot >=2.2.0.RELEASE and <2.4.0-M1",
"1.5.1": "Spring Boot >=2.4.0-M1 and <2.4.1",
"2.0.1": "Spring Boot >=2.4.1 and <2.5.0-M1"
},
"mybatis": {
"2.1.4": "Spring Boot >=2.1.0.RELEASE and <2.5.0-M1"
},
"camel": {
"3.3.0": "Spring Boot >=2.2.0.RELEASE and <2.3.0.M1",
"3.5.0": "Spring Boot >=2.3.0.M1 and <2.4.0-M1",
"3.9.0": "Spring Boot >=2.4.0.M1 and <2.5.0-M1"
},
"open-service-broker": {
"3.1.1.RELEASE": "Spring Boot >=2.2.0.RELEASE and <2.3.0.M1",
"3.2.0": "Spring Boot >=2.3.0.M1 and <2.4.0-M1",
"3.3.0": "Spring Boot >=2.4.0-M1 and <2.5.0-M1"
}
}
}

3、Spring Cloud组件的停更、升级、替换

Spring Cloud入门以及版本管理_版本号