Mercurial > hg > nginx
comparison src/http/ngx_http_spdy.h @ 5530:827e53c136b0
SPDY: use ngx_queue_t to queue streams for post processing.
It simplifies the code and allows easy reuse the same queue pointer to store
streams in various queues with different requirements. Future implementation
of SPDY/3.1 will take advantage of this quality.
author | Valentin Bartenev <vbart@nginx.com> |
---|---|
date | Mon, 20 Jan 2014 20:56:49 +0400 |
parents | e4adaa47af65 |
children | 01e2a5bcdd8f |
comparison
equal
deleted
inserted
replaced
5529:e4adaa47af65 | 5530:827e53c136b0 |
---|---|
94 ngx_connection_t *free_fake_connections; | 94 ngx_connection_t *free_fake_connections; |
95 | 95 |
96 ngx_http_spdy_stream_t **streams_index; | 96 ngx_http_spdy_stream_t **streams_index; |
97 | 97 |
98 ngx_http_spdy_out_frame_t *last_out; | 98 ngx_http_spdy_out_frame_t *last_out; |
99 ngx_http_spdy_stream_t *last_stream; | 99 |
100 ngx_queue_t posted; | |
100 | 101 |
101 ngx_http_spdy_stream_t *stream; | 102 ngx_http_spdy_stream_t *stream; |
102 | 103 |
103 ngx_uint_t entries; | 104 ngx_uint_t entries; |
104 size_t length; | 105 size_t length; |
114 struct ngx_http_spdy_stream_s { | 115 struct ngx_http_spdy_stream_s { |
115 ngx_uint_t id; | 116 ngx_uint_t id; |
116 ngx_http_request_t *request; | 117 ngx_http_request_t *request; |
117 ngx_http_spdy_connection_t *connection; | 118 ngx_http_spdy_connection_t *connection; |
118 ngx_http_spdy_stream_t *index; | 119 ngx_http_spdy_stream_t *index; |
119 ngx_http_spdy_stream_t *next; | |
120 | 120 |
121 ngx_uint_t header_buffers; | 121 ngx_uint_t header_buffers; |
122 ngx_uint_t queued; | 122 ngx_uint_t queued; |
123 | 123 |
124 ngx_http_spdy_out_frame_t *free_frames; | 124 ngx_http_spdy_out_frame_t *free_frames; |
125 ngx_chain_t *free_data_headers; | 125 ngx_chain_t *free_data_headers; |
126 ngx_chain_t *free_bufs; | 126 ngx_chain_t *free_bufs; |
127 | |
128 ngx_queue_t queue; | |
127 | 129 |
128 unsigned priority:2; | 130 unsigned priority:2; |
129 unsigned handled:1; | 131 unsigned handled:1; |
130 unsigned blocked:1; | 132 unsigned blocked:1; |
131 unsigned in_closed:1; | 133 unsigned in_closed:1; |