Skip to content

Commit c604f6b

Browse files
authored
Send GOAWAY (#233)
HTTP/2 connection sends GOAWAY on error, or during normal shutdown.
1 parent 9e5564e commit c604f6b

File tree

4 files changed

+273
-70
lines changed

4 files changed

+273
-70
lines changed

include/aws/http/private/h2_connection.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,14 @@ struct aws_h2_connection {
9595
* Defaults to max stream-id, may be lowered when GOAWAY frame received. */
9696
uint32_t goaway_received_last_stream_id;
9797

98+
/* Last-stream-id sent in most recent GOAWAY frame. Defaults to max stream-id. */
99+
uint32_t goaway_sent_last_stream_id;
100+
101+
/* Cached channel shutdown values.
102+
* If possible, we delay shutdown-in-the-write-dir until GOAWAY is written. */
103+
int channel_shutdown_error_code;
104+
bool channel_shutdown_immediately;
105+
bool channel_shutdown_waiting_for_goaway_to_be_written;
98106
} thread_data;
99107

100108
/* Any thread may touch this data, but the lock must be held (unless it's an atomic) */

0 commit comments

Comments
 (0)