## Spring Cloud简介
Spring Cloud是一系列框架的有序集合。它利用Spring Boot的开发便利性巧妙地简化了分布式系统基础设施的开发,如服务发现注册、配置中心、消息总线、负载均衡、断路器、数据监控等,都可以用Spring Boot的开发风格做到一键启动和部署。Spring并没有重复制造轮子,它只是将目前各家公司开发的比较成熟、经得起实际考验的服务框架组合起来,通过Spring Boot风格进行再封装屏蔽掉了复杂的配置和实现原理,最终给开发者留出了一套简单易懂、易部署和易维护的分布式系统开发工具包。
微服务是可以独立部署、水平扩展、独立访问(或者有独立的数据库)的服务单元,springcloud就是这些微服务的大管家,采用了微服务这种架构之后,项目的数量会非常多。Spring Cloud提供的全套的分布式系统解决方案,自然需要很多子项目来帮忙。
## SpringCloud的子项目

* Spring Cloud Config:配置管理工具,支持使用Git存储配置内容,支持应用配置的外部化存储,支持客户端配置信息刷新、加解密配置内容等
* Spring Cloud Bus:事件、消息总线,用于在集群(例如,配置变化事件)中传播状态变化,可与Spring Cloud Config联合实现热部署。
* Spring Cloud Netflix:针对多种Netflix组件提供的开发工具包,其中包括Eureka、Hystrix、Zuul、Archaius等。
* Netflix Eureka:一个基于rest服务的服务治理组件,包括服务注册中心、服务注册与服务发现机制的实现,实现了云端负载均衡和中间层服务器的故障转移。
* Netflix Hystrix:容错管理工具,实现断路器模式,通过控制服务的节点,从而对延迟和故障提供更强大的容错能力。
* Netflix Ribbon:客户端负载均衡的服务调用组件。
* Netflix Feign:基于Ribbon和Hystrix的声明式服务调用组件。
* Netflix Zuul:微服务网关,提供动态路由,访问过滤等服务。
* Netflix Archaius:配置管理API,包含一系列配置管理API,提供动态类型化属性、线程安全配置操作、轮询框架、回调机制等功能。
* Spring Cloud for Cloud Foundry:通过Oauth2协议绑定服务到CloudFoundry,CloudFoundry是VMware推出的开源PaaS云平台。
* Spring Cloud Sleuth:日志收集工具包,封装了Dapper,Zipkin和HTrace操作。
* Spring Cloud Data Flow:大数据操作工具,通过命令行方式操作数据流。
* Spring Cloud Security:安全工具包,为你的应用程序添加安全控制,主要是指OAuth2。
* Spring Cloud Consul:封装了Consul操作,consul是一个服务发现与配置工具,与Docker容器可以无缝集成。
* Spring Cloud Zookeeper:操作Zookeeper的工具包,用于使用zookeeper方式的服务注册和发现。
* Spring Cloud Stream:数据流操作开发包,封装了与Redis,Rabbit、Kafka等发送接收消息。
* Spring Cloud CLI:基于 Spring Boot CLI,可以让你以命令行方式快速建立云组件。
## SpringCloud与Dubbo的区别

## 版本号说明
### 常见版本号说明
软件版本号:2.3.0 SNAPSHOT
2:主版本号。当功能模块有较大更新或者整体架构发生变化时,主版本号会更新
0:次版本号。次版本表示只是局部的一些变动。
2:修改版本号。一般是bug的修复或者是小的变动
SNAPSHOT:希腊字母版本号。次版本号用户标注当前版本的软件处于哪个开发阶段
### 希腊字母版本号
Base:设计阶段。只有相应的设计没有具体的功能实现。
Alpha:软件的初级版本。存在较多的bug
Bate:表示相对alpha有了很大的进步,消除了严重的bug,还存在一些潜在的bug。
RC:(Release Candidate):候选版本,几乎就是正式版了
SNAPSHOT:快照版,可以稳定使用,且仍在继续改进版本
GA:(Ggeneral Availability):发行稳定版,官方推荐使用此版
Release:该版本表示最终版
### Spring Cloud版本号说明
* 为什么Spring Cloud版本用的是单词而不是数字?
设计的目的是为了更好的管理每个Spring Cloud的子项目的清单。避免子的版本号与子项目的版本号混淆。
* 版本号单词的定义规则
采用伦敦的地铁站名称来作为版本号的命名,根据首字母排序,字母顺序靠后的版本号越大。
## Spring Boot和Spring Cloud各个版本兼容情况
来源:https://start.spring.io/actuator/info
```
{
"git":{
"commit":{
"time":"2020-05-11T09:40:30Z",
"id":"603a742"
},
"branch":"603a7422e6179901256205c33b37d09438a2e4f5"
},
"build":{
"version":"0.0.1-SNAPSHOT",
"artifact":"start-site",
"name":"start.spring.io website",
"versions":{
"initializr":"0.9.0.BUILD-SNAPSHOT",
"spring-boot":"2.2.7.RELEASE"
},
"group":"io.spring.start",
"time":"2020-05-11T09:41:32.785Z"
},
"bom-ranges":{
"azure":{
"2.0.10":"Spring Boot >=2.0.0.RELEASE and <2.1.0.RELEASE",
"2.1.7":"Spring Boot >=2.1.0.RELEASE and <2.2.0.M1",
"2.2.0":"Spring Boot >=2.2.0.M1"
},
"codecentric-spring-boot-admin":{
"2.0.6":"Spring Boot >=2.0.0.M1 and <2.1.0.M1",
"2.1.6":"Spring Boot >=2.1.0.M1 and <2.2.0.M1",
"2.2.3":"Spring Boot >=2.2.0.M1"
},
"solace-spring-boot":{
"1.0.0":"Spring Boot >=2.2.0.RELEASE and <2.3.0.M1"
},
"solace-spring-cloud":{
"1.0.0":"Spring Boot >=2.2.0.RELEASE and <2.3.0.M1"
},
"spring-cloud":{
"Finchley.M2":"Spring Boot >=2.0.0.M3 and <2.0.0.M5",
"Finchley.M3":"Spring Boot >=2.0.0.M5 and <=2.0.0.M5",
"Finchley.M4":"Spring Boot >=2.0.0.M6 and <=2.0.0.M6",
"Finchley.M5":"Spring Boot >=2.0.0.M7 and <=2.0.0.M7",
"Finchley.M6":"Spring Boot >=2.0.0.RC1 and <=2.0.0.RC1",
"Finchley.M7":"Spring Boot >=2.0.0.RC2 and <=2.0.0.RC2",
"Finchley.M9":"Spring Boot >=2.0.0.RELEASE and <=2.0.0.RELEASE",
"Finchley.RC1":"Spring Boot >=2.0.1.RELEASE and <2.0.2.RELEASE",
"Finchley.RC2":"Spring Boot >=2.0.2.RELEASE and <2.0.3.RELEASE",
"Finchley.SR4":"Spring Boot >=2.0.3.RELEASE and <2.0.999.BUILD-SNAPSHOT",
"Finchley.BUILD-SNAPSHOT":"Spring Boot >=2.0.999.BUILD-SNAPSHOT and <2.1.0.M3",
"Greenwich.M1":"Spring Boot >=2.1.0.M3 and <2.1.0.RELEASE",
"Greenwich.SR5":"Spring Boot >=2.1.0.RELEASE and <2.1.15.BUILD-SNAPSHOT",
"Greenwich.BUILD-SNAPSHOT":"Spring Boot >=2.1.15.BUILD-SNAPSHOT and <2.2.0.M4",
"Hoxton.SR4":"Spring Boot >=2.2.0.M4 and <2.3.0.BUILD-SNAPSHOT",
"Hoxton.BUILD-SNAPSHOT":"Spring Boot >=2.3.0.BUILD-SNAPSHOT"
},
"spring-cloud-alibaba":{
"2.2.1.RELEASE":"Spring Boot >=2.2.0.RELEASE and <2.3.0.M1"
},
"spring-cloud-services":{
"2.0.3.RELEASE":"Spring Boot >=2.0.0.RELEASE and <2.1.0.RELEASE",
"2.1.7.RELEASE":"Spring Boot >=2.1.0.RELEASE and <2.2.0.RELEASE",
"2.2.3.RELEASE":"Spring Boot >=2.2.0.RELEASE and <2.3.0.M1"
},
"spring-statemachine":{
"2.0.0.M4":"Spring Boot >=2.0.0.RC1 and <=2.0.0.RC1",
"2.0.0.M5":"Spring Boot >=2.0.0.RC2 and <=2.0.0.RC2",
"2.0.1.RELEASE":"Spring Boot >=2.0.0.RELEASE"
},
"vaadin":{
"10.0.17":"Spring Boot >=2.0.0.M1 and <2.1.0.M1",
"14.1.28":"Spring Boot >=2.1.0.M1"
},
"wavefront":{
"2.0.0-RC1":"Spring Boot >=2.1.0.RELEASE and <2.3.0.BUILD-SNAPSHOT",
"2.0.0-SNAPSHOT":"Spring Boot >=2.3.0.BUILD-SNAPSHOT"
}
},
"dependency-ranges":{
"okta":{
"1.2.1":"Spring Boot >=2.1.2.RELEASE and <2.2.0.M1",
"1.4.0":"Spring Boot >=2.2.0.M1"
},
"mybatis":{
"2.0.1":"Spring Boot >=2.0.0.RELEASE and <2.1.0.RELEASE",
"2.1.2":"Spring Boot >=2.1.0.RELEASE"
},
"geode":{
"1.2.6.RELEASE":"Spring Boot >=2.2.0.M5 and <2.3.0.M1",
"1.3.0.M4":"Spring Boot >=2.3.0.M1 and <2.3.0.BUILD-SNAPSHOT",
"1.3.0.BUILD-SNAPSHOT":"Spring Boot >=2.3.0.BUILD-SNAPSHOT"
},
"camel":{
"2.22.4":"Spring Boot >=2.0.0.M1 and <2.1.0.M1",
"2.25.1":"Spring Boot >=2.1.0.M1 and <2.2.0.M1",
"3.2.0":"Spring Boot >=2.2.0.M1"
}
}
}
```

走入Spring Cloud的世界