|
|
@ -329,6 +329,7 @@ void grpc_chttp2_list_add_writing_stalled_by_transport( |
|
|
|
grpc_chttp2_transport_writing *transport_writing, |
|
|
|
grpc_chttp2_transport_writing *transport_writing, |
|
|
|
grpc_chttp2_stream_writing *stream_writing) { |
|
|
|
grpc_chttp2_stream_writing *stream_writing) { |
|
|
|
grpc_chttp2_stream *stream = STREAM_FROM_WRITING(stream_writing); |
|
|
|
grpc_chttp2_stream *stream = STREAM_FROM_WRITING(stream_writing); |
|
|
|
|
|
|
|
gpr_log(GPR_DEBUG, "writing stalled %d", stream->global.id); |
|
|
|
if (!stream->included[GRPC_CHTTP2_LIST_WRITING_STALLED_BY_TRANSPORT]) { |
|
|
|
if (!stream->included[GRPC_CHTTP2_LIST_WRITING_STALLED_BY_TRANSPORT]) { |
|
|
|
GRPC_CHTTP2_STREAM_REF(&stream->global, "chttp2_writing_stalled"); |
|
|
|
GRPC_CHTTP2_STREAM_REF(&stream->global, "chttp2_writing_stalled"); |
|
|
|
} |
|
|
|
} |
|
|
@ -336,22 +337,28 @@ void grpc_chttp2_list_add_writing_stalled_by_transport( |
|
|
|
GRPC_CHTTP2_LIST_WRITING_STALLED_BY_TRANSPORT); |
|
|
|
GRPC_CHTTP2_LIST_WRITING_STALLED_BY_TRANSPORT); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
void grpc_chttp2_list_flush_writing_stalled_by_transport( |
|
|
|
bool grpc_chttp2_list_flush_writing_stalled_by_transport( |
|
|
|
grpc_exec_ctx *exec_ctx, grpc_chttp2_transport_writing *transport_writing) { |
|
|
|
grpc_exec_ctx *exec_ctx, grpc_chttp2_transport_writing *transport_writing) { |
|
|
|
grpc_chttp2_stream *stream; |
|
|
|
grpc_chttp2_stream *stream; |
|
|
|
|
|
|
|
bool out = false; |
|
|
|
grpc_chttp2_transport *transport = TRANSPORT_FROM_WRITING(transport_writing); |
|
|
|
grpc_chttp2_transport *transport = TRANSPORT_FROM_WRITING(transport_writing); |
|
|
|
while (stream_list_pop(transport, &stream, |
|
|
|
while (stream_list_pop(transport, &stream, |
|
|
|
GRPC_CHTTP2_LIST_WRITING_STALLED_BY_TRANSPORT)) { |
|
|
|
GRPC_CHTTP2_LIST_WRITING_STALLED_BY_TRANSPORT)) { |
|
|
|
|
|
|
|
gpr_log(GPR_DEBUG, "move %d from writing stalled to just stalled", |
|
|
|
|
|
|
|
stream->global.id); |
|
|
|
grpc_chttp2_list_add_stalled_by_transport(transport_writing, |
|
|
|
grpc_chttp2_list_add_stalled_by_transport(transport_writing, |
|
|
|
&stream->writing); |
|
|
|
&stream->writing); |
|
|
|
GRPC_CHTTP2_STREAM_UNREF(exec_ctx, &stream->global, |
|
|
|
GRPC_CHTTP2_STREAM_UNREF(exec_ctx, &stream->global, |
|
|
|
"chttp2_writing_stalled"); |
|
|
|
"chttp2_writing_stalled"); |
|
|
|
|
|
|
|
out = true; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
return out; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
void grpc_chttp2_list_add_stalled_by_transport( |
|
|
|
void grpc_chttp2_list_add_stalled_by_transport( |
|
|
|
grpc_chttp2_transport_writing *transport_writing, |
|
|
|
grpc_chttp2_transport_writing *transport_writing, |
|
|
|
grpc_chttp2_stream_writing *stream_writing) { |
|
|
|
grpc_chttp2_stream_writing *stream_writing) { |
|
|
|
|
|
|
|
gpr_log(GPR_DEBUG, "stalled %d", stream_writing->id); |
|
|
|
stream_list_add(TRANSPORT_FROM_WRITING(transport_writing), |
|
|
|
stream_list_add(TRANSPORT_FROM_WRITING(transport_writing), |
|
|
|
STREAM_FROM_WRITING(stream_writing), |
|
|
|
STREAM_FROM_WRITING(stream_writing), |
|
|
|
GRPC_CHTTP2_LIST_STALLED_BY_TRANSPORT); |
|
|
|
GRPC_CHTTP2_LIST_STALLED_BY_TRANSPORT); |
|
|
|