Spring Cloud微服务简介
概述
Spring Cloud给开发者提供一套按照一定套路快速开发分布式工具。它为微服务架构中涉及**配置管理,服务治理,断路器,智能路由,微代理,控制总线,全局锁,分布式会话和集群状态等操作提供了一种简单的开放方式。
SpringCloud组成
Spring Cloud 1.xxx版本和Spring Cloud 2.xxx版本中,其中在Spring Cloud Netflix核心组件的依赖标识名发生了变化。
1:Spring Cloud Config
分布式配置管理,支持使用Git存储配置内容,可以使用它实现应用配置的外部化存储,并支持客户端配置信息刷新,加密/加密配置内容等。
2:Spring Cloud Netflix核心组件
Eureka 服务治理组件,包含服务注册中心,服务注册与发现机制的实现。(服务治理,服务注册/发现)
Hystrix 容错管理逐渐,实现断路器模式,帮助服务以来中出现的延迟和为故障提供强大的容错能力。(熔断、断路器,容错)
Ribbon 客户端负载 均和的服务调用组件(客户端负载)
Feigin 给予Ribbon和Hystrix的声明式服务调用组件 (声明式服务调用)
Zuul 网关组件,提供智能路由,访问过滤功能
3:Spring Cloud Bus:消息总线
4:Spring Cloud Sleuth:分布式跟踪实现,可以完美整合Zipkin
5:Spring Cloud Security:安全工具包,提供在Zuul代理中的OAuth2客户端请求的中继器
6:Spring Cloud Zookeeper:Zookeeper的服务发现与配置管理组件
7:Spring Boot Admin:微服务监控UI页面
8:Spring Cloud Stream:通过Redis,Rabbit或者Kafka实现消费微服务,可以通过简单的声明式模型发送和接收消息。消息微服务驱动
Spring Cloud 1.xxx和Spring Cloud 2.xxx中Netflix组件版本依赖变化
1.xxx版本
<!--Eureka服务治理组件-->
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-eureka-server</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-eureka</artifactId>
</dependency>
<!--断路器组件-->
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-hystrix</artifactId>
</dependency>
<!--声明式服务调用-->
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-feign</artifactId>
</dependency>
<!--负载均衡组件-->
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-ribbon</artifactId>
</dependency>
<!--智能路由组件-->
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-zuul</artifactId>
</dependency>
2.xxx版本
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-netflix-eureka-server</artifactId>
</dependency>2.xxx版本和1.xxx版本加上了netflix。
Spring Cloud 演示项目地址:https://gitee.com/ley1996/spring-cloud-learn
Spring Cloud微服务简介的更多相关文章
- 1、Spring Cloud - 微服务简介
前言: 业界大牛马丁.福勒(Martin Fowler) 这样描述微服务: 论文网址:https://martinfowler.com/articles/microservices.html 就目前而 ...
- Spring Cloud微服务中网关服务是如何实现的?(Zuul篇)
导读 我们知道在基于Spring Cloud的微服务体系中,各个微服务除了在内部提供服务外,有些服务接口还需要直接提供给客户端,如Andirod.IOS.H5等等. 而一个很尴尬的境地是,如果直接将提 ...
- Spring Cloud微服务安全实战_00_前言
一.前言: 一直以来对服务安全都很感兴趣,所以就学习.这是学习immoc的 jojo老师的 <Spring Cloud微服务安全实战课程>的笔记,讲的很好. 课程简介: 二.最终形成的架 ...
- spring cloud微服务实践七
在spring cloud 2.x以后,由于zuul一直停滞在1.x版本,所以spring官方就自己开发了一个项目 Spring Cloud Gateway.作为spring cloud微服务的网关组 ...
- Spring Cloud微服务系列文,服务调用框架Feign
之前博文的案例中,我们是通过RestTemplate来调用服务,而Feign框架则在此基础上做了一层封装,比如,可以通过注解等方式来绑定参数,或者以声明的方式来指定请求返回类型是JSON. 这种 ...
- Spring Cloud 微服务
https://mp.weixin.qq.com/s?__biz=MzU0OTE4MzYzMw==&mid=2247486301&idx=2&sn=f6d45860269b61 ...
- 一张图了解Spring Cloud微服务架构
Spring Cloud作为当下主流的微服务框架,可以让我们更简单快捷地实现微服务架构.Spring Cloud并没有重复制造轮子,它只是将目前各家公司开发的比较成熟.经得起实际考验的服务框架组合起来 ...
- 如何优化Spring Cloud微服务注册中心架构?
作者: 石杉的架构笔记 1.再回顾:什么是服务注册中心? 先回顾一下什么叫做服务注册中心? 顾名思义,假设你有一个分布式系统,里面包含了多个服务,部署在不同的机器上,然后这些不同机器上的服务之间要互相 ...
- Spring Cloud微服务下的权限架构调研
随着微服务架构的流行,系统架构调整,项目权限系统模块开发提上日程,需要对权限架构进行设计以及技术选型.所以这段时间看了下相关的资料,做了几个对比选择. 一.架构图 初步设想的架构如下,结构很简单:eu ...
随机推荐
- dom4j解析xml获取所有的子节点并放入map中
dom4j递归解析所有子节点 //解析返回的xml字符串,生成document对象 Document document = DocumentHelper.parseText(resultXml); / ...
- 如何使用egit将本地代码提交到托管平台
本文将讲述如何使用eclipse中的egit插件,将代码提交到git托管平台. Eclipse版本:4.7.0 自带egit插件 云端托管平台:华为软件开发云 1.本地git工具安装&环境配置 ...
- 更改linux的最大文件描述符限制
To ensure good server performance, the total number of client connections, database files, and log f ...
- JavaScript(js)获取本周,本月,本季,本年,上月,上周,上季,去年,上二周,上二月的时间段的代码
function dateChange(name){ var beginTimeObject = document.getElementById("beginTime"); var ...
- Adaptive device-initiated polling
A method includes periodically sending a polling call to an enterprise system outside the firewall a ...
- Java transient关键字【转】
转自:http://www.blogjava.net/fhtdy2004/archive/2009/06/20/286112.htmlVolatile修饰的成员变量在每次被线程访问时,都强迫从主内存中 ...
- 从DOS bat启动停止SQL Server (MSSQLSERVER)服务
由于机器上装了SQL Server2008,导致机器开机变慢,没办法只能让SQL Server (MSSQLSERVER) 服务默认不启动.但是每次要使用SQL Server时就必须从控制面板-管理 ...
- Scala(一) 环境搭建和HelloWorld
环境 scala 1.12.2 JDK 1.8.0_131 Win10 Eclipse 4.6.1 软件下载 官网:http://www.scala-lang.org/ 点击DOWNLOAD进 ...
- Distinct去除重复项
之前在做权限模块时,因不同角色可能拥有相同的菜单,导致呈现在浏览器上时出现重复菜单项,所以需要在获取用户拥有菜单项时需要过滤重复项, 用到了Distinct,两个重载 public static IQ ...
- what is the difference between definition and declaration in c
A declaration introduces an identifier and describes its type, be it a type, object, or function. A ...