zoukankan      html  css  js  c++  java
  • 3.spring cloud eureka 高可用

    1、目的 防止某一台服务器宕机 通常通过多台EUREKA来为客户端进行注册,客户也进行注册

    2、开启三台EUREKA

     三天EUREKA分别对应端口 8761 8762 8763

    配置文件如下

    EUREKA1

    eureka:
      client:
        service-url:
          defaultZone: http://localhost:8762/eureka,http://localhost:8763/eureka
        register-with-eureka: false
      server:
        enable-self-preservation: false
    spring:
      application:
        name: eureka
    #server:
    # port: 8761
    management:
      context-path: /

    EUREKA2

    eureka:
      client:
        service-url:
          defaultZone: http://localhost:8761/eureka,http://localhost:8763/eureka
        register-with-eureka: false
      server:
        enable-self-preservation: false
    spring:
      application:
        name: eureka
    #server:
    # port: 8761
    management:
      context-path: /

    EUREKA3

    eureka:
      client:
        service-url:
          defaultZone: http://localhost:8761/eureka,http://localhost:8762/eureka
        register-with-eureka: false
      server:
        enable-self-preservation: false
    spring:
      application:
        name: eureka
    #server:
    # port: 8761
    management:
      context-path: /

    CLIENT

    eureka:
      client:
        service-url:
          defaultZone: http://localhost:8761/eureka/,http://localhost:8762/eureka/,http://localhost:8763/eureka/
    spring:
      application:
        name: client

    3.启动客户端和三台EUREKA

    8761

    8762

    8763

  • 相关阅读:
    IOS之helloworld
    xcode4.2中创建Navigation-Based Application
    IOS之数据持久化
    IOS之多视图应用程序
    IOS之高级控件表视图
    IOS之基本UI控件
    IOS之导航控制器与表视图
    IOS之应用程序设置
    IOS之高级控件拾取器
    IOS之UI基础
  • 原文地址:https://www.cnblogs.com/shuaihan/p/9999655.html
Copyright © 2011-2022 走看看