Welcome! Log In Create A New Profile

Advanced

[nginx] SPDY: avoid setting timeout on stream events in ngx_http...

Valentin Bartenev
August 27, 2014 12:48PM
details: http://hg.nginx.org/nginx/rev/11790b461a6f
branches:
changeset: 5813:11790b461a6f
user: Valentin Bartenev <vbart@nginx.com>
date: Wed Aug 27 20:44:11 2014 +0400
description:
SPDY: avoid setting timeout on stream events in ngx_http_writer().

The SPDY module doesn't expect timers can be set on stream events for reasons
other than delaying output. But ngx_http_writer() could add timer on write
event if the delayed flag wasn't set and nginx is waiting for AIO completion.
That could cause delays in sending response over SPDY when file AIO was used.

diffstat:

src/http/ngx_http_request.c | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)

diffs (16 lines):

diff -r 954867a2f0a6 -r 11790b461a6f src/http/ngx_http_request.c
--- a/src/http/ngx_http_request.c Tue Aug 19 15:43:26 2014 +0400
+++ b/src/http/ngx_http_request.c Wed Aug 27 20:44:11 2014 +0400
@@ -2656,6 +2656,12 @@ ngx_http_writer(ngx_http_request_t *r)

if (r->buffered || r->postponed || (r == r->main && c->buffered)) {

+#if (NGX_HTTP_SPDY)
+ if (r->spdy_stream) {
+ return;
+ }
+#endif
+
if (!wev->delayed) {
ngx_add_timer(wev, clcf->send_timeout);
}

_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

[nginx] SPDY: avoid setting timeout on stream events in ngx_http...

Valentin Bartenev 687 August 27, 2014 12:48PM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 97
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready