一、只执行一次 nginx.conf get_timer_at.lua 文件 执行请求后:curl http://127.0.0.1/ngx_timer_at 执行 5 s 后打印以下内容在日志文件中 二、不停的循环,和while 一样的结果 执行请求后:curl http://127.0.0.1/ ...
分类:
其他好文 时间:
2017-05-05 00:54:02
阅读次数:
537
xilanglangdeMacBook-Pro:pcre xinshaofeng$ brew link pcre Linking /usr/local/Cellar/pcre/8.40... Error: Could not symlink bin/pcre-config Target /usr/l ...
分类:
其他好文 时间:
2017-04-28 20:23:08
阅读次数:
423
1. ecs 购买 地域: 华北 2 可用区: 随机分配 安全组 ID: sg-2533jog6k I/O 优化实例: I/O 优化实例 实例规格: 1 核 1GB 网络类型: 经典网络 带宽: 1Mbps(按固定带宽) 镜像: CentOS 7.2 64位 系统盘: 40GB 高效云盘 密码: 已 ...
分类:
Web程序 时间:
2017-04-24 00:57:59
阅读次数:
917
一、默认配置AB压力测试 官方nginx/1.10.3 测试结果: openresty/1.11.2.1测试结果: ...
分类:
其他好文 时间:
2017-04-22 18:52:21
阅读次数:
243
源码:nginx 1.12.0 一、nginx http模块简介 由于nginx的性能优势,现在已经有越来越多的单位、个人采用nginx或者openresty、tengine等衍生版来作为WEB服务器、负载均衡服务器、安全网关来使用。在这些场景下,依赖的就是nginx的http模块,nginx的设计 ...
分类:
Web程序 时间:
2017-04-22 17:31:03
阅读次数:
280
官网:http://openresty.org/en/installation.html 先下载pcre-8.40,openssl-1.0.1u //验证过此版本。其他版本有问题!!!! ...
分类:
其他好文 时间:
2017-04-18 15:09:10
阅读次数:
147
1. 安装 luarocks install lua-resty-template 2. 使用 luarocks install lua-resty-template 2. 使用 配置模板页面位置 有多种方式: a. 直接使用root 目录 代码如下: location /{ root html; ...
分类:
其他好文 时间:
2017-04-04 23:25:18
阅读次数:
1166
openresty websocket 使用 1. 代码如下: local server =require"resty.websocket.server" local wb, err = server:new{ timeout =5000, max_payload_len =65535 } ifno ...
分类:
Web程序 时间:
2017-04-03 12:42:09
阅读次数:
860
在玩ngx-lua时候有个 resty-uuid 需要引用 libuuid.so 动态库 打印log提示信息是这样的: libuuid.so: cannot open shared object file: No such file or directory 解决方案: [root@iZwz9afh... ...
分类:
其他好文 时间:
2017-03-30 21:56:54
阅读次数:
139
1、打开网址:https://openresty.org/en/download.html,看最新的版本号,比如说现在的版本号是1.11.2.1 2、wget https://openresty.org/download/openresty-1.11.2.1.tar.gz 3、tar zxvf op ...
分类:
其他好文 时间:
2017-03-17 00:39:03
阅读次数:
544