Eureka architecture and high availability cluster replication principle

Eureka architecture

Service registration and discovery Eureka (Eureka Server), divided into service providers, service consumers. (Eureka Client)
1, the service provider -> Registration Center: Registration Register, renew Renew, off the assembly line the Cancel
2, registry <- Service Provider: get the registry information Registry the Get
3, customer service -> Registration Center: get the registry information
4, consumer services -> service provider: remote call
5, registration center by replicating peer, service consumers get the registry information, call the remote service provider

Eureka cluster replication principle

High availability cluster: You can register another way to achieve by running multiple instances and Eureka server. Synchronized with each other between the information gain Server node, thus ensuring consistency of data nodes.

peer startup process:
1, pulling its peer registry.
2, registers itself to the peer.
3, after the completion of 2, 2 will peer synchronized to it, peer in the peer 2.

spring:
  profiles: 7901
server: 
  port: 7901
eureka:
  instance:
    hostname: eureka-7901  
  client:
    #设置服务注册中心的URL,向该注册中心注册
    service-url:                      
      defaultZone: http://root:root@eureka-7902:7902/eureka/
Published 25 original articles · won praise 0 · Views 575

Guess you like

Origin blog.csdn.net/RaymondCoder/article/details/105174454