spring-cloud-config笔记
spring-cloud-config 简单来讲就是spring-cloud实现的分布式配置中心.与之前介绍的开源配置服务方案 disconf是一样的,spring-cloud-config分为服务与客户两端
spring-cloud-config 使用git或者svn 甚至是本地的文件系统作为配置文件的仓库
spring-cloud-config 用application,profile,label 三个维度来实现分布式配置管理和发布.
application : 使用spring-cloud-config服务的客户端名称
profile : 这个很好理, manve的profile概念基本一致 可以理解成环境
lable : 这个可以理解成版本,如果使用的是git作为配置管理的仓库,label可以是分支名,tag的名称

spring-cloud-config的原理就是 将远程git仓库中的配置文件clone到本地临时目录并加载至内存中
spring-cloud-config客户端通过URL的形式来获取配置,spring官网的介绍如下
/{application}/{profile}[/{label}] /{application}-{profile}.yml /{label}/{application}-{profile}.yml /{application}-{profile}.properties /{label}/{application}-{profile}.properties
客户端可以通过http GET 请求直接获取spring-cloud-server的配置,实际应用中则不需要这样获取,只需要配置服务的host即可,如果使用Eureka,则只需要配置服务端的服务即可
与开源方案disconf的对比
控制台:
disconf : 拥有自己的web界面管理配置
spring-cloud-config: 没有web界面维护配置,主要靠git,svn等操作管理配置
推拉模型:
disconfi: 通过zookeeper实现推模型,拉模型
spring-cloud-config: 通过git,svn实现 推拉模型
配置存储:
disconf: 通过数据库存储配置
spring-cloud-config:通过git,以及本地文件的形式存储配置文件
配置管理及发布:
disconf : 拥有 环境,app,version 管理及发布配置.
spring-cloud-config : 通过 application,profile , label 管理发布配置
部署:
disconf: web程序,既是控制台也是服务,高可用方案依赖nginx,zookeeper
spring-cloud-config: spring-boot程序, 高可用方案依赖spring-cloud技术方案
通过对比,disconf的优势是管理配置简单,而spring-cloud-config的优势是与我们的spring-cloud技术方案完美的集成,不需要单独的考虑高可用方案
而且spring-cloud-config部署方式也优于disconf,使用git对于程序员非常的熟悉,而且git天生对版本的支持也是spring-cloud-config的优势 鸣谢崔老大.
spring-cloud-config笔记的更多相关文章
- SpringCloud学习笔记(7):使用Spring Cloud Config配置中心
简介 Spring Cloud Config为分布式系统中的外部化配置提供了服务器端和客户端支持,服务器端统一管理所有配置文件,客户端在启动时从服务端获取配置信息.服务器端有多种配置方式,如将配置文件 ...
- Spring Cloud学习笔记【九】配置中心Spring Cloud Config
Spring Cloud Config 是 Spring Cloud 团队创建的一个全新项目,用来为分布式系统中的基础设施和微服务应用提供集中化的外部配置支持,它分为服务端与客户端两个部分.其中服务端 ...
- 分布式配置中心:Spring Cloud Config
最近在学习Spring Cloud的知识,现将分布式配置中心:Spring Cloud Config的相关知识笔记整理如下.[采用 oneNote格式排版]
- spring cloud config 入门
简介 Spring cloud config 分为两部分 server client config-server 配置服务端,服务管理配置信息 config-client 客户端,客户端调用serve ...
- Spring Cloud Config
Spring Cloud Config provides server and client-side support for externalized configuration in a dist ...
- Spring Cloud 学习笔记(一)——入门、特征、配置
[TOC] 0 放在前面 0.1 参考文档 http://cloud.spring.io/spring-cloud-static/Brixton.SR7/ https://springcloud.cc ...
- Spring Cloud官方文档中文版-Spring Cloud Config(上)
官方文档地址为:http://cloud.spring.io/spring-cloud-static/Dalston.SR2/#spring-cloud-feign 文中例子我做了一些测试在:http ...
- Spring Cloud官方文档中文版-Spring Cloud Config(下)-客户端等
官方文档地址为:http://cloud.spring.io/spring-cloud-static/Dalston.SR2/#_serving_alternative_formats 文中例子我做了 ...
- SpringCloud的配置管理:Spring Cloud Config
演示如何使用ConfigServer提供统一的参数配置服务 ###################################################################一.概 ...
- 搭建spring cloud config
很久没更新了,因为不是专职研究spring cloud,因此更新速度得看工作强度大不大,每天能抽出的时间不多,如果更新太慢了,并且有小伙伴看的话,请见谅了. Spring Cloud简介 Spring ...
随机推荐
- [转]Spring MVC 4常用的那些注解
Spring从2.5版本开始在编程中引入注解,用户可以使用@RequestMapping, @RequestParam, @ModelAttribute等等这样类似的注解.到目前为止,Spring的版 ...
- 安装配置convirture
Author: Jin Date: 20130627 Title: 安装配置convirture 参考: http://www.convirture.com/wiki/index.php?title= ...
- Jenkins用HTTP Request Plugin插件进行网站的监控/加探针(运维监控)
使用的插件: [HTTP Request Plugin] 思路: 说明:只能是网站是否正常打开,而不能是这个网站业务是否正常,如果是后者,则需要写特定的接口进行请求处理. 1.通过插件,发送GET请求 ...
- NHibernate官方文档中文版--ISessionFactory的配置(ISessionFactory Configuration)
由于NHibernate是被设计应用在许多不同环境中的,因此它存在很多配置参数.幸运的是,这些参数大多都有合理的默认值,而且NHibernate发布的时候伴随着一个App.config 例子(可在sr ...
- HDU 2389 Rain on your Parade(二分匹配,Hopcroft-Carp算法)
Rain on your Parade Time Limit: 6000/3000 MS (Java/Others) Memory Limit: 655350/165535 K (Java/Ot ...
- django--02 模板的使用
参考链接:https://www.w3cschool.cn/django/django-template.html 1.新建模板目录 templates 2.在setting文件中注册模板 修改 T ...
- java多线程处理导入数据拆分List集合 同步处理插入数据
原文:https://www.2cto.com/kf/201612/581174.html import org.apache.log4j.Logger; import org.apache.poi. ...
- meteor学习-- #一 安装meteor快速使用
下载安装 curl https://install.meteor.com/ | sh meteor会自动下载mongodb和其他需要依赖的库,不需要手动安装. 如果是Windows 的用户,请使用 m ...
- Android 卡顿优化 4 布局优化实际技巧
今天分享一些layout布局书写中的一些技巧,希望看过之后你也一样可以写出性价比高的布局.我个人的目标是用最少的View写出一样效果的布局.因为我相信View的数量减少伴随着的就是层级的减少.从而达到 ...
- [转载]Delphi 版 everything、光速搜索代码
近日没啥事情,研究了一下 everything.光速搜索原理.花了一个礼拜时间,终于搞定. 废话不多说,直接上代码: unit uMFTSearchFile; { dbyoung@sina.com 2 ...