Yichun Zhang
Yichun Zhang
@usirsiwal Yes, you're right. And copying all the request headers to the subrequest is exactly what the latest ngx_lua git master does in its subrequest API.
I think we can just disable these directives in the context of subrequests for now.
@hamishforbes An additional return value can break backward compatibility, for example, ``` foo(ngx.req.get_uri_args(), "some other things") ``` will not work as expected because the second argument now becomes the 3rd,...
@hamishforbes You beat me :) Another flag argument looks artificial to me as well. I would have a hard time documenting this argument if we implemented it. Raising default error...
@hamishforbes Oh, seems like there's another way. How about adding an empty metatable to the resulting table in case of truncation? This won't break existing code I suppose and you...
@hamishforbes Yes.
@hamishforbes Instead of creating a new table upon every call, we could reuse and share a single empty table. It's supposed to be read-only anyway.
@hamishforbes Maybe you can find this helpful: http://www.lua.org/manual/5.1/manual.html#luaL_newmetatable
@hamishforbes Yes. Please go ahead :) Though I'm still not 100% happy with this approach ;)
Maybe you can cooperate with @pintsized in his lua-resty-redis-connector project or alike? Please see https://groups.google.com/d/topic/openresty-en/0yr32RqZ8L0/discussion