Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Openresty Update #1272

Merged
merged 13 commits into from
May 24, 2021
Merged
4 changes: 2 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -109,12 +109,12 @@ executors:
environment:
S2I_VERSION: "1.1.12-2a783420"
DOCKER_COMPOSE_VERSION: "1.16.1"
OPENRESTY_VERSION: "1.17.5.1-0-centos8"
OPENRESTY_VERSION: "1.19.3.1-0-centos8"

openresty:
working_directory: /opt/app-root/apicast
docker:
- image: quay.io/3scale/s2i-openresty-centos7:1.17.5.1-0-centos8
- image: quay.io/3scale/s2i-openresty-centos7:1.19.3.1-0-centos8
- image: redis:3.2.8-alpine
environment:
TEST_NGINX_BINARY: openresty
Expand Down
2 changes: 1 addition & 1 deletion gateway/src/resty/ctx.lua
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ function _M.ref()

local _ = ngx.ctx -- load context

local ctx_ref = C.ngx_http_lua_ffi_get_ctx_ref(r)
local ctx_ref = C.ngx_http_lua_ffi_get_ctx_ref(r, ffi.new("int[1]"), ffi.new("int[1]"))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What does this do?

Copy link
Contributor Author

@eloycoto eloycoto May 19, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The C call definition changed, and now it needs to pass a integer.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why 1? Does it matter? Or we can just send anything?
Would be good to clarify with a comment.


if ctx_ref == FFI_NO_REQ_CTX then
return error("no request ctx found")
Expand Down