我试了下...还真是这样....
[root@dev-docker ~]# ab -n 20 www.x1.com/hello-count
This is ApacheBench, Version 2.3 <$Revision: 1430300 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/
Benchmarking www.x1.com (be patient).....done
Server Software: openresty/1.13.6.1
Server Hostname: www.x1.com
Server Port: 80
Document Path: /hello-count
Document Length: 12 bytes
Concurrency Level: 1
Time taken for tests: 0.011 seconds
Complete requests: 20
Failed requests: 0
Write errors: 0
Total transferred: 3790 bytes
HTML transferred: 240 bytes
Requests per second: 1787.15 [#/sec] (mean)
Time per request: 0.560 [ms] (mean)
Time per request: 0.560 [ms] (mean, across all concurrent requests)
Transfer rate: 330.73 [Kbytes/sec] received
Connection Times (ms)
min mean[+/-sd] median max
Connect: 0 0 0.0 0 0
Processing: 0 0 0.3 0 1
Waiting: 0 0 0.3 0 1
Total: 0 1 0.3 0 2
ERROR: The median and mean for the total time are more than twice the standard
deviation apart. These results are NOT reliable.
Percentage of the requests served within a certain time (ms)
50% 0
66% 0
75% 0
80% 0
90% 1
95% 2
98% 2
99% 2
100% 2 (longest request)
[root@dev-docker ~]# curl www.x1.com/hello-count
<html>
<head><title>503 Service Temporarily Unavailable</title></head>
<body bgcolor="white">
<center><h1>503 Service Temporarily Unavailable</h1></center>
<hr><center>openresty/1.13.6.1</center>
</body>
</html>
[root@dev-docker ~]# curl www.x2.com/hello-count
<html>
<head><title>503 Service Temporarily Unavailable</title></head>
<body bgcolor="white">
<center><h1>503 Service Temporarily Unavailable</h1></center>
<hr><center>openresty/1.13.6.1</center>
</body>
</html>
[root@dev-docker ~]# curl www.x3.com/hello-count
<html>
<head><title>503 Service Temporarily Unavailable</title></head>
<body bgcolor="white">
<center><h1>503 Service Temporarily Unavailable</h1></center>
<hr><center>openresty/1.13.6.1</center>
</body>
</html>
在 2018年6月11日星期一 UTC+8上午9:31:23,c moo0写道:
比如:
我定义了 这俩个字典
lua_shared_dict my_limit_count_store 100m;
lua_shared_dict my_limit_req_store 100m;
然后我在 3个server_name 里使用了lua限流脚本
那么这2个字典在这三个 server主机里是共享的吗? 如果是的话 当其中一个key在 其中一个server主机里计算器跑满了,那么别的server主机也就无法访问了。 - -
在 2018年6月11日星期一 UTC+8上午9:31:23,c moo0写道:
比如:
我定义了 这俩个字典
lua_shared_dict my_limit_count_store 100m;
lua_shared_dict my_limit_req_store 100m;
然后我在 3个server_name 里使用了lua限流脚本
那么这2个字典在这三个 server主机里是共享的吗? 如果是的话 当其中一个key在 其中一个server主机里计算器跑满了,那么别的server主机也就无法访问了。 - -