Current Behavior
Brotli plugin is sending partial response from the apisix.
Expected Behavior
The last chunk is not present in the response.
Full response should be provided.
eof flag should not overwrite the arg[1], but it(arg[1]) should be appended with compressor:finish().
Error Logs
curl -i https://cluster.local/reviews/ -H 'Accept-Encoding: br,gzip'
HTTP/2 200
content-type: text/html; charset=utf-8
date: Fri, 22 Mar 2024 09:43:16 GMT
x-frame-options: SAMEORIGIN
vary: Cookie
set-cookie: csrftoken=4OBETSI9vldc5nXxgCiNbyJLg8xGgyLoN4phqdmQulIvNYiCPTnRMdqTPUKYFVhY; expires=Fri, 21 Mar 2025 09:43:16 GMT; Max-Age=31449600; Path=/; SameSite=Lax
server: zen
access-control-allow-origin: *
access-control-allow-methods: GET,PUT,POST,DELETE,PATCH,OPTIONS
access-control-max-age: 1728000
access-control-expose-headers: *
access-control-allow-headers: DNT,Keep-Alive,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Range,Authorization
strict-transport-security: max-age=31536000; includeSubdomains; preload
access-control-allow-credentials: true
x-xss-protection: 1
x-content-type-options: nosniff
content-encoding: br
curl: (92) HTTP/2 stream 1 was not closed cleanly: PROTOCOL_ERROR (err 1)
Steps to Reproduce
Configure brotli, and enable the plugin, and try sending the request to the route.
Environment
- APISIX version (run
apisix version): latest
- Operating system (run
uname -a): NA
- OpenResty / Nginx version (run
openresty -V or nginx -V): NA
- etcd version, if relevant (run
curl http://127.0.0.1:9090/v1/server_info): NA
- APISIX Dashboard version, if relevant: NA
- Plugin runner version, for issues related to plugin runners: NA
- LuaRocks version, for installation issues (run
luarocks --version): NA
Current Behavior
Brotli plugin is sending partial response from the apisix.
Expected Behavior
The last chunk is not present in the response.
Full response should be provided.
eofflag should not overwrite thearg[1], but it(arg[1]) should be appended withcompressor:finish().Error Logs
Steps to Reproduce
Configure
brotli, and enable the plugin, and try sending the request to the route.Environment
apisix version): latestuname -a): NAopenresty -Vornginx -V): NAcurl http://127.0.0.1:9090/v1/server_info): NAluarocks --version): NA