Hello!
On Wed, Jun 19, 2013 at 11:42:57PM -0600, Julien Zefi wrote:
> i tried to follow the suggestion of using a timer and a new handler for the
> write callback without luck, indeed there is something wrong on my end.
>
> if you have some minute to review, I wrote a simple test case, my goal is
> to make ngx_http_test_stream_handler(..) to be called every 10ms and send
> some data to the browser until this same function decide to stop working...
Two obvious problems:
1) You try to send data from stack, which is wrong as nginx might
not be able to send data immediately.
2) You set timer only once. Note timers are not periodic, and
this will result in only call of the timer handler function.
Haven't looked any further.
--
Maxim Dounin
http://nginx.org/en/donation.html
_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel
On Wed, Jun 19, 2013 at 11:42:57PM -0600, Julien Zefi wrote:
> i tried to follow the suggestion of using a timer and a new handler for the
> write callback without luck, indeed there is something wrong on my end.
>
> if you have some minute to review, I wrote a simple test case, my goal is
> to make ngx_http_test_stream_handler(..) to be called every 10ms and send
> some data to the browser until this same function decide to stop working...
Two obvious problems:
1) You try to send data from stack, which is wrong as nginx might
not be able to send data immediately.
2) You set timer only once. Note timers are not periodic, and
this will result in only call of the timer handler function.
Haven't looked any further.
--
Maxim Dounin
http://nginx.org/en/donation.html
_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel