lua-nginx-module
lua-nginx-module copied to clipboard
lj_str_new high CPU usague when performance testing
I found lj_str_new high cpu usague
-
env OpenResty-1.15.8,OS:CentOS6,CPU: Intel(R) Xeon(R) CPU E5-2620 v4 @ 2.10GHz, 15 worker http request 8k ~10k,10w qps
-
lj_str_new high cpu usague when access_by_lua of ngx_lua

You can try passing in the string length when calling ffi.string.
str = ffi.string(ptr [,len])
thx,i try