1. springcloud1.5.x的消息总线配置是

# RabbitMq的地址、端口,用户名、密码
spring.rabbitmq.host=localhost
spring.rabbitmq.port=5672
spring.rabbitmq.username=guest
spring.rabbitmq.password=guest
# 保证调用 /bus/refresh的时候不需要验证
management.security.enabled=false

configServer的启动类加上注解@RefreshScope

configClient的启动类也加上注解@RefreshScope

修改github上的配置文件之后,打开postman,请求方式是post,地址是http://localhost:8881/bus/refresh,这个端口号是configServer的。

请求成功之后,返回的是空白,此时configClient就能获取到最新的配置信息。

2.  springcloud2.x的消息总线配置是

# RabbitMq的地址、端口,用户名、密码
spring.rabbitmq.host=localhost
spring.rabbitmq.port=5672
spring.rabbitmq.username=guest
spring.rabbitmq.password=guest # 刷新配置,在spring boot 2.x 之前1.x的management.security.enabled失效,新的配置为
management.endpoints.web.exposure.include=bus-refresh

configServer的启动类加上注解@RefreshScope

configClient的启动类也加上注解@RefreshScope

修改github上的配置文件之后,打开postman,请求方式是post,地址是http://localhost:8881/actuator/bus-refresh,这个端口号是configServer的。

请求成功之后,返回的是空白,此时configClient就能获取到最新的配置信息。

3. 需要注意的是configClient也要配置RabbiMq。

springcloud2.x之management.security.enabled=false报错处理的更多相关文章

  1. Spring Boot 2.x中的management.security.enabled=false无效问题

    look: https://blog.csdn.net/qq_27385301/article/details/82899303

  2. springboot2.0 management.security.enabled无效

    在1.5.x版本中通过management.security.enabled=false来暴露所有端点 在使用springcloud的时候,如果基于springboot2的版本的配置中心,无法使用SV ...

  3. 状态栏 a.getBoolean(1, false) 报错

    状态栏 a.getBoolean(1, false) 报错 这个错误在编译运行时候并不会出现,但是当需要编译打包的时候,就会报出这个异常. TypedArray a = mContext.obtain ...

  4. bug日志-天坑,Spring Security的登陆报错:An internal error occurred while trying to authenticate the user.

    在学习Spring Security的时候,我的编辑器给我报错:An internal error occurred while trying to authenticate the user. 明明 ...

  5. onsubmit="return false;"报错

    <form id="formpersonal" method="post" onsubmit="return false;">. ...

  6. These relative modules were not found:...{"sourceM ap":false} 报错解决

    今天在使用vue2.0 + webpack 时,没有动过任何配置文件,也没更新依赖,但是报下面的错误: These relative modules were not found: * ./star1 ...

  7. AndroidManifest设置android:allowBackup="false"报错

    概述 设置android:allowBackup="false"的必要性 Android API Level 8及其以上Android系统提供了为应用程序数据的备份和恢复功能,此功 ...

  8. 解决 MyEclipse 10 中 JSp页面 “return false” 报错问题

    1.MyEclipse ->. Preferences 2.validation ->>找到JavaScript validator for Js files  builder 下面 ...

  9. spring cloud-config的client中/refresh的端点报错401

    post访问/refresh端口报错如下 { "timestamp": 1537865395040, "status": 401, "error&qu ...

随机推荐

  1. playtime-浙大羽协裁判部训练方案[随机事件序列的应用]

    首先随机一列人名 然后按比例随机一列事件项. 然后将不确定项的人名更正为“某人”[比如发球违例,,,你怎么知道谁在发球] 最后定义一个初始化. 初始化呢,就是挑边. 球权还是场权? 发球还是接发? 谁 ...

  2. 云原生生态周报 Vol. 14 | K8s CVE 修复指南

    业界要闻 Mesosphere 公司正式更名为 D2IQ, 关注云原生. Mesosophere 公司日前发布官方声明正式更名为:D2iQ(Day-Two-I-Q),称关注点转向 Kubernetes ...

  3. OfType<string>()

    object[] vals = { 1, "Hello", true, "World", 9.1 }; IEnumerable<double> ju ...

  4. 咕咕咕-HLPP算法

    hlpp(欢乐婆婆)算法总结 突然发现咕了好久(X) emm先大概说一下,hlpp是针对网络流算法的一种复杂度更优的算法,基于预流推进(即模拟) 复杂度上界为 n2根号m 且跑不满 (所以学会了它,可 ...

  5. apache-tomcat-7.0.94在Windows上启动时,控制台黑窗口出现乱码解决

    一.问题 二.解决 原因是tomcat日志编码的配置问题. 打开tomcat/conf/logging.properties配置文件. 把编码注释掉或者改为gbk就可以了. 参考:https://bl ...

  6. web前端-bootstrap

    1.什么是bootstrap 前端开发开源工具包 ,包含css样式库+jq插件 ,ui效果非常好 ,都是通过给标签加class选择器来实现功能的 2.特点 响应式布局:使用栅格系统可以把页面呈现在不同 ...

  7. CATransform3D 特效详解

    http://blog.sina.com.cn/s/blog_8f5097be0101b91z.html

  8. swift中文版和网站

    http://www.chinaz.com/swift/chapter2/01_The_Basics.html http://www.iphonetrain.com/video_info/290.ht ...

  9. 配置全文搜索引擎solr

    前言 solr是apache下的一个子项目,用java编写基于Lucene开发的全文搜索服务器,不同于Lucene,solr一个完成的搜索服务器,提供了众多接口调用,而Lucene只是个工具包.如果用 ...

  10. appium 基础:常用api接口(2)

    一.获取手机分辨率 size=driver.get_window_size()#获取手机屏幕大小,分辨率 print(size)#{'width': 720, 'height': 1280} 得到的是 ...