openresty / openresty/lua-nginx-module
body_filter_by_lua_file breaks with multiple output_buffers and aio=threads
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 11.8k
- Forks
- 2.1k
- Avg merge
- 6h 1m
- Merged PRs (30d)
- 6
Description
Hi
Since nginx version 1.9.5, the default value for output_buffers changed from "1 32k" to "2 32k"
If multiple output_buffers are defined, and aio threads/threadpools are enabled and there is any script set to run at body_filter_by_lua then the connection is closed at 32k
It's not a major issue for me as I just changed it back to 1 32k, but I thought you would like to know about it
Thanks
Richard
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the failure with nginx 1.9.5 or later, multiple output_buffers, aio=threads or a thread pool, and a body_filter_by_lua script. Trace the lua-nginx-module body-filter entry point and output-buffer handling around the 32k boundary. Done means responses larger than 32k no longer close the connection under this configuration.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- lua, nginx
- Domain
- backend, performance
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100