当前位置: 首页 > news >正文

专做定制旅游网站有哪些最新新闻十条

专做定制旅游网站有哪些,最新新闻十条,网站关键词分隔符,东营企业网站seoRate Limiting限流插件 https://docs.konghq.com/hub/kong-inc/rate-limiting/ 它可以针对consumer ,credential ,ip ,service,path,header 等多种维度来进行限流.流量控制的精准度也有多种方式可以参考,比如可以做到秒级,分钟级,小时级等限流控制. 基于IP限流 源码地址 kong/kong/plugins/ip-restriction/handler.lua at master · Kong/kong · GitHub local lrucache require resty.lrucache local ipmatcher require resty.ipmatcher local kong_meta require kong.metalocal error error local kong kong local log kong.log local ngx_var ngx.varlocal IPMATCHER_COUNT 512 local IPMATCHER_TTL 3600 local cache lrucache.new(IPMATCHER_COUNT)local IpRestrictionHandler {PRIORITY 990,VERSION kong_meta.version, }local isempty dolocal tb_isempty require table.isemptyisempty function(t)return t nil or tb_isempty(t)end endlocal function do_exit(status, message)status status or 403message message orstring.format(IP address not allowed: %s, ngx_var.remote_addr)log.warn(message)return kong.response.error(status, message) endlocal function match_bin(list, binary_remote_addr)local matcher, errmatcher cache:get(list)if not matcher thenmatcher, err ipmatcher.new(list)if err thenreturn error(failed to create a new ipmatcher instance: .. err)endcache:set(list, matcher, IPMATCHER_TTL)endlocal is_matchis_match, err matcher:match_bin(binary_remote_addr)if err thenreturn error(invalid binary ip address: .. err)endreturn is_match endlocal function do_restrict(conf)local binary_remote_addr ngx_var.binary_remote_addrif not binary_remote_addr thenreturn do_exit(403,Cannot identify the client IP address, ..unix domain sockets are not supported.)endlocal deny conf.denyif not isempty(deny) thenlocal blocked match_bin(deny, binary_remote_addr)if blocked thenreturn do_exit(conf.status, conf.message)endendlocal allow conf.allowif not isempty(allow) thenlocal allowed match_bin(allow, binary_remote_addr)if not allowed thenreturn do_exit(conf.status, conf.message)endend endfunction IpRestrictionHandler:access(conf)return do_restrict(conf) endfunction IpRestrictionHandler:preread(conf)return do_restrict(conf) endreturn IpRestrictionHandler
http://www.w-s-a.com/news/652458/

相关文章:

  • 张家界网站建设方案中国网页设计师
  • 淮南网站建设服务东莞营销型手机网站建设
  • 常德做网站专业公司河南高端网站建设
  • 网站服务器建设的三种方法会展设计ppt
  • 如何把自己做的网站放到内网seo优化网络
  • 北京网站建设net2006厦门优化公司
  • 制作网页前为什么要建立站点菏泽百度网站建设
  • 做影视网站引流网页美工设计课程教案
  • 响应式网站开发流程图网站优化seo教程
  • 做汽车团购网站百度官网平台
  • 网站增加关键字建设旅游网站的功能定位
  • 怎么搭建源码网站义乌网络
  • 定远规划建设局网站wordpress云主机安装
  • 慈溪市网站开发软件开发文档国家标准
  • 本地佛山顺德网站设计公司的网站如何建设
  • 网站建设前十名网站建设 招标书
  • 手机网站标准百度搜索关键词排名优化推广
  • 中国空间站科幻作文1000字wordpress运行库
  • 徐州做网站的wordpress可视化编辑器排行
  • 官方网站英语上海公司注册核名查询
  • 东莞网站建设推广云南昆明最新消息
  • 上网站乱码网页设计与网站建设案例教程
  • 宣讲网站建设wordpress多媒体主题
  • 如何成立网站互联网开发是做什么的
  • 网站首页的尺寸做多大网页图片排版
  • 龙岩天宫山索道多少钱河南网站排名优化哪家好
  • 北京做网站设计程序员和网站开发
  • 个人 做自媒体 建网站图片制作成视频的手机软件
  • h5 建站网站 移动端重庆潼南网站建设价格
  • 商企在线营销型网站怎么做时光网站