<div dir="ltr">Hi.<div>I'm writing simple module for Nginx just to fork process on request and execute some separate process and then exit.</div><div><br></div><div><i>if(fork() == 0)</i></div><div><i>{</i></div><div><i>       // Use r  request pointer</i></div><div><i>.</i></div><div><i>.</i></div><div><i>.</i></div><div><i>   // creating out_chain (could be more than 700kb)</i></div><div><i>    ngx_http_output_filter ( r , out_chain );</i></div><div><i>    ngx_http_finalize_request(r, NGX_OK);<br></i></div><div><i>}</i></div><div><i>else</i></div><div><i>{</i></div><div><i>       close(r->connection->fd); </i></div><div><i>       ngx_http_finalize_request(r, NGX_OK);<br></i></div><div><i>}</i></div><div><br></div><div>if I'm sending 1 request per time it works fine , but when I'm sending 2 or more requests at the same time works only the last request , other requests just staying in loading stage.</div><div><br></div><div>Who can help me figure out what is the problem ?</div><div><br></div><div>I'm just thinking it could be because ngx_request_t *r pointer is in nginx shared memory so every request overriding another .... but maybe it's not about that.</div><div><br></div><div>Please let me know if you can give any help.</div><div><br></div><div>Thanks.</div></div>