1.服务发现组件:Eureka

Eureka的开源文档介绍地址:https://github.com/Netflix/eureka/wiki/Eureka-at-a-glance

What is Eureka?

Eureka is a REST (Representational State Transfer) based service that is primarily used in the AWS cloud for locating services for the purpose of load balancing and failover of middle-tier servers. We call this service, the Eureka Server. Eureka also comes with a Java-based client component,the Eureka Client, which makes interactions with the service much easier. The client also has a built-in load balancer that does basic round-robin load balancing. At Netflix, a much more sophisticated load balancer wraps Eureka to provide weighted load balancing based on several factors like traffic, resource usage, error conditions etc to provide superior resiliency.

翻译:

Eureka是一种基于REST(Representational State Transfer)的服务,主要用于AWS云(亚马逊云计算服务),用于定位服务,以实现中间层服务器的负载平衡和故障转移。 我们将此服务称为Eureka Server。 Eureka还附带了一个基于Java的客户端组件Eureka Client,它使与服务的交互变得更加容易。 客户端还有一个内置的负载均衡器,可以进行基本的循环负载均衡。 在Netflix,一个更复杂的负载均衡器包含Eureka基于流量,资源使用,错误条件等多种因素提供加权负载平衡,以提供卓越的弹性。

What is the need for Eureka?

In AWS cloud, because of its inherent nature, servers come and go. Unlike the traditional load balancers which work with servers with well known IP addresses and host names, in AWS, load balancing requires much more sophistication in registering and de-registering servers with load balancer on the fly. Since AWS does not yet provide a middle tier load balancer, Eureka fills a big gap in the area of mid-tier load balancing.

翻译:

在AWS云中,由于其固有的特性,服务器来来去去。 与使用具有众所周知的IP地址和主机名的服务器的传统负载均衡器不同,在AWS中,负载均衡在使用负载均衡器注册和取消注册服务器时需要更加复杂。 由于AWS尚未提供中间层负载均衡器,因此Eureka填补了中间层负载均衡领域的巨大空白。

High level architecture

The architecture above depicts how Eureka is deployed at Netflix and this is how you would typically run it. There is one eureka cluster per region which knows only about instances in its region. There is at the least one eureka server per zone to handle zone failures.

Services register with Eureka and then send heartbeats to renew their leases every 30 seconds. If the client cannot renew the lease for a few times, it is taken out of the server registry in about 90 seconds. The registration information and the renewals are replicated to all the eureka nodes in the cluster. The clients from any zone can look up the registry information (happens every 30 seconds) to locate their services (which could be in any zone) and make remote calls.

翻译:

上面的架构描述了如何在Netflix上部署Eureka,这就是您通常如何运行它。 每个地区只有一个尤里卡群集,它只知道该地区的实例。 每个区域至少有一个eureka服务器来处理区域故障。

服务在Eureka注册,然后发送心跳每30秒更新一次租约。 如果客户端无法续订租约几次,则会在大约90秒内将其从服务器注册表中删除。 注册信息和续订将复制到群集中的所有eureka节点。 来自任何区域的客户端都可以查找注册表信息(每30秒发生一次)以查找其服务(可能位于任何区域中)并进行远程调用。

Eureka是简单,便捷,高可用。

从零开始学spring cloud(三) -------- Eureka简介的更多相关文章

  1. 从零开始学spring cloud(八) -------- Eureka 高可用机制

    一.Eureka高可用机制介绍 Eureka服务器没有后端存储,但注册表中的服务实例都必须发送心跳以使其注册保持最新(因此可以在内存中完成). 客户端还有一个Eureka注册的内存缓存(因此,他们不必 ...

  2. spring cloud之eureka简介

    最近线上的接口出了一些问题,有一些可能不是代码的问题,但是由于是测试和其他方面的同事爆出来的,所以感觉对接口的监控应该提上日程. 经过搜索发现,spring cloud的eureka就是专门做这方面工 ...

  3. 从零开始学spring cloud(五) -------- 将服务注册到Eureka上

    一.开发前准备工作: 官方文档地址:https://cloud.spring.io/spring-cloud-static/spring-cloud-netflix/2.1.0.RELEASE/mul ...

  4. 从零开始学spring cloud(十一) -------- hystrix监控

    一.官方文档阅读 服务启动后,可以通过/health和hystrix.stream查看效果,实际上,访问上述两个地址,会出现404,这是因为spring boot版本的问题, 我在这里使用的sprin ...

  5. 从零开始学spring cloud(七) -------- Spring Cloud OpenFegin

    一.OpenFegin 介绍 Feign是一个声明性的Web服务客户端. 它使编写Web服务客户端变得更容易. 要使用Feign,请创建一个界面并对其进行注释. 它具有可插入的注释支持,包括Feign ...

  6. 从零开始学spring cloud(六) -------- Ribbon

    一.Ribbon介绍 Ribbon就是客户端侧负责均衡实现的一种方式,那么Ribbon是什么呢? Ribbon是Netflix发布的云中间层服务开源项目,其主要功能是提供客户端侧负载均衡算法.Ribb ...

  7. 从零开始学spring cloud(四) -------- 基础项目搭建

    1.创建一个spring cloud项目 1.1.使用工具创建--idea 点击creat new project,选择spring initializr 点击next,选择下一步 填入自己的Grou ...

  8. 从零开始学spring cloud(一) -------- spring cloud 简介

    1.微服务简介 1.1.单体架构 一个归档包(例如war格式)包含了应用所有功能的应用程序,我们通常称之为单体应用.架构单体应用的方法论,我们称之为单体应用架构. 缺点:1. 复杂性高以笔者经手的一个 ...

  9. 从零开始学spring cloud(十) -------- hystrix简单代码示例

    一.官网文档阅读 较低级别的服务中的服务故障可能导致级联故障一直到用户. 当对特定服务的调用超过circuitBreaker.requestVolumeThreshold(默认值:20个请求)且失败百 ...

随机推荐

  1. 20175311 2018-2019-2 《Java程序设计》第四周学习总结

    20175311 2018-2019-2 <Java程序设计>第4周学习总结 教材学习内容总结 这一周在上一周的基础上更进一步,主要学习了子类的继承.super关键字的用法含义.继承与多态 ...

  2. idea git commit撤销

    到项目目录下,打开git bash 1.git log 找到要撤销的版本id1 commit之前的版本id2 2.git reset –hard id13.git reset id2 参考链接:htt ...

  3. vue学习笔记(一)--Tab切换

    最近在学Vue,写的第一个demo是Tab,刚开始还直接把js代码贴过来改,没觉得有什么不同.然后请教别人说,用Vue最好不要操作dom啦,又把代码做了修改-_-. html代码如下: <div ...

  4. php中一个"异类"语法: $a && $b = $c; 【转载】

    $a = 1;$b = 2;$c = 3;$a && $b = $c;echo "a:$a";echo "b:$b";echo "c: ...

  5. LeetCode 104. Maximum Depth of Binary Tree二叉树的最大深度 C++/Java

    Given a binary tree, find its maximum depth. The maximum depth is the number of nodes along the long ...

  6. 1. maven 手动添加jar包

    mvn install:install-file -Dfile=isc_sso_agent-1.0.jar -DgroupId=com.sgcc.isc -DartifactId=isc_sso_ag ...

  7. [DOM]初识DOM

    文档对象模型(Document Object Model,简称DOM),是W3C组织推荐的处理可扩展标志语言的标准编程接口.在网页上,组织页面(或文档)的对象被组织在一个树形结构中,用来表示文档中对象 ...

  8. JavaScript字符串操作方法大全,包含ES6方法

    一.charAt() 返回在指定位置的字符. var str="abc" console.log(str.charAt(0))//a 二.charCodeAt() 返回在指定的位置 ...

  9. 两将军问题、拜占庭将军问题、TCP三路握手过程的联系

    2015年初时产生了一个疑问:基于不可靠的通信链路,为什么在两将军问题中永远无法达到共识,而在TCP三路握手中可以? 今天抽出了一些时间进行研究发现,实际上TCP三路握手也不是完全可靠的,只是一个近似 ...

  10. 快速干掉Windows Defender

    1.快捷键Win+R,调出"运行"对话框,输入"gpedit.msc",打开组策略编辑器: 2.展开"计算机配置"→"管理模板&q ...