Skip to content

Avoid processing or writing channel frames after connection.close - #124

Merged
michalovits merged 1 commit into
mainfrom
close-conn-chan
Dec 2, 2026
Merged

michalovits merged 1 commit into
mainfrom
close-conn-chan

Conversation

@michalovits

@michalovits michalovits commented Dec 1, 2026 •

Copy link
Copy Markdown
Contributor

Avoid processing or writing channel frames after connection.close from either party. Eagerly reset channels at the connection state transition, instead of always waiting for socketShutdown.

Taking care to:

  • avoid double channel reopen from back to back channel.close and connection.close (dedupe by lifetime ID)
  • avoid accessing the message store on ack write completion if the channel is destroyed in between

@michalovits
michalovits added this pull request to stack #126 December 1, 2026 18:04
@michalovits
michalovits force-pushed the close-conn-chan branch 4 times, most recently from 80ac782 to 36a6e3b Compare December 2, 2026 11:53
@michalovits michalovits changed the title Close channels upon sending connection.close Avoid processing or writing channel frames after connection.close Dec 2, 2026
@michalovits
michalovits force-pushed the close-conn-chan branch 3 times, most recently from 87551f9 to b90516d Compare December 2, 2026 13:28
@michalovits
michalovits marked this pull request as ready for review December 2, 2026 14:41
@michalovits
michalovits enabled stacked auto-merge (squash) December 2, 2026 14:41
@michalovits
michalovits merged commit e070dcb into main Dec 2, 2026
9 checks passed
@michalovits
michalovits deleted the close-conn-chan branch December 2, 2026 14:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants