流控规则页面,例如原先阈值=20,编辑单机阈值修改成100保存成功后,页面显示100,当请求触发限流约束的接口后,阈值从100变回20,单机阈值规则没有在客户端生效
1、先调用"http://localhost:8719/getRules?type=flow" 查询到"count":20.0,也就是预设值
2、页面上编辑count=120,推送到本地内存,再次查询发现count=120
3、URL触发正常接口
4、再次查询"http://localhost:8719/getRules?type=flow",发现count=20
本地sentinel-record.log.2018-12-27 2018-12-27 10:20:46 [FlowRuleManager] Flow rules received: {HelloWorld=[FlowRule{resource=HelloWorld, limitApp=default, grade=1, count=20.0, strategy=0, refResource=null, controlBehavior=0, warmUpPeriodSec=10, maxQueueingTimeMs=500, clusterMode=false, clusterConfig=null, controller=com.alibaba.csp.sentinel.slots.block.flow.controller.DefaultController@30ef9122}]} 2018-12-27 10:21:14 Receiving rule change (type: flow): [{"clusterMode":false,"controlBehavior":0,"count":120.0,"grade":1,"limitApp":"default","maxQueueingTimeMs":500,"resource":"HelloWorld","strategy":0,"warmUpPeriodSec":10}] 2018-12-27 10:21:14 [DynamicSentinelProperty] Config will be updated to: [FlowRule{resource=HelloWorld, limitApp=default, grade=1, count=120.0, strategy=0, refResource=null, controlBehavior=0, warmUpPeriodSec=10, maxQueueingTimeMs=500, clusterMode=false, clusterConfig=null, controller=null}] 2018-12-27 10:21:14 [FlowRuleManager] Flow rules received: {HelloWorld=[FlowRule{resource=HelloWorld, limitApp=default, grade=1, count=120.0, strategy=0, refResource=null, controlBehavior=0, warmUpPeriodSec=10, maxQueueingTimeMs=500, clusterMode=false, clusterConfig=null, controller=com.alibaba.csp.sentinel.slots.block.flow.controller.DefaultController@1b3dee38}]} 2018-12-27 10:21:35 [DynamicSentinelProperty] Config will be updated to: [FlowRule{resource=HelloWorld, limitApp=default, grade=1, count=20.0, strategy=0, refResource=null, controlBehavior=0, warmUpPeriodSec=10, maxQueueingTimeMs=500, clusterMode=false, clusterConfig=null, controller=null}] 2018-12-27 10:21:35 [FlowRuleManager] Flow rules received: {HelloWorld=[FlowRule{resource=HelloWorld, limitApp=default, grade=1, count=20.0, strategy=0, refResource=null, controlBehavior=0, warmUpPeriodSec=10, maxQueueingTimeMs=500, clusterMode=false, clusterConfig=null, controller=com.alibaba.csp.sentinel.slots.block.flow.controller.DefaultController@217efcc5}]}
原提问者GitHub用户bobo612
版权声明:本文内容由阿里云实名注册用户自发贡献,版权归原作者所有,阿里云开发者社区不拥有其著作权,亦不承担相应法律责任。具体规则请查看《阿里云开发者社区用户服务协议》和《阿里云开发者社区知识产权保护指引》。如果您发现本社区中有涉嫌抄袭的内容,填写侵权投诉表单进行举报,一经查实,本社区将立刻删除涉嫌侵权内容。
阿里云拥有国内全面的云原生产品技术以及大规模的云原生应用实践,通过全面容器化、核心技术互联网化、应用 Serverless 化三大范式,助力制造业企业高效上云,实现系统稳定、应用敏捷智能。拥抱云原生,让创新无处不在。