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

echo_subrequest_async with cosocket #3

Closed
GuillaumeMar opened this issue May 4, 2012 · 3 comments
Closed

echo_subrequest_async with cosocket #3

GuillaumeMar opened this issue May 4, 2012 · 3 comments

Comments

@GuillaumeMar
Copy link

Hi,

I'm reading incoming content of nginx with cosocket, like this :

local clientsock = ngx.req.socket()
...
local req_body, err, partial = clientsock:receive(2048)
...

And then I call an async method with the req_body, for each stream:

echo_subrequest_async PUT /test -q 'md5=$arg_md5' -b $echo_request_body;

But after one request done I got this error:
2012/05/04 13:12:42 [error] 20906#0: *1 lua socket read timed out while sending to client, client: 1.2.3.4, server: , request: "PUT /file.tgz HTTP/1.1", host: "xxxx"

With echo_subrequest it works good.

Any idea? :)
Thx

@agentzh
Copy link
Owner

agentzh commented May 4, 2012

On Fri, May 4, 2012 at 7:28 PM, Kaim
reply@reply.github.com
wrote:

I'm reading incoming content of nginx with cosocket, like this :

local clientsock = ngx.req.socket()
...
local req_body, err, partial = clientsock:receive(2048)
...

And then I call an async method with the req_body, for each stream:

echo_subrequest_async PUT /test -q 'md5=$arg_md5'  -b $echo_request_body;

But after one request done I got this error:
2012/05/04 13:12:42 [error] 20906#0: *1 lua socket read timed out while sending to client, client: 1.2.3.4, server: , request: "PUT /file.tgz HTTP/1.1", host: "xxxx"

With echo_subrequest it works good.

Which version of ngx_lua or ngx_openresty are you using? If you're not
using ngx_openresty 1.0.15.1, could you please try it out?

Also, could you please give a minimized but still complete config
example that can reproduce this issue? I'm not quite understand how
your Lua code interact with your ngx_echo configurations.

Thank you for the report!
-agentzh

P.S. please report ngx_openresty related issues to the ngx_openresty
github project:

https://github.com/agentzh/ngx_openresty/issues/

The openresty project is for the old Perl implementation for OpenResty.

Thanks!
-agentzh

@HakChealKim
Copy link

configure file;
my mac can not find the configure file, whats the root cause?

@agentzh
Copy link
Owner

agentzh commented Aug 21, 2017

Wrong project. The old openresty is dead.

@agentzh agentzh closed this as completed Aug 21, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants