Skip to content

Conversation

@Lukasa
Copy link
Contributor

@Lukasa Lukasa commented Aug 14, 2020

Motivation:

We temporarily store channel creation requests in NIOSSHHandler before
passing them to the multiplexer while we wait for the handshake to
complete. This is fine, but if for any reason we get removed from the
pipeline while we're still holding some, they must all be cancelled.

Modifications:

  • Correctly cancel creation requests on handlerRemoved.
  • Verify behaviour in tests.

Result:

Fewer hangs on channel creation.

Actually fixes #36.

Motivation:

We temporarily store channel creation requests in NIOSSHHandler before
passing them to the multiplexer while we wait for the handshake to
complete. This is fine, but if for any reason we get removed from the
pipeline while we're still holding some, they must all be cancelled.

Modifications:

- Correctly cancel creation requests on handlerRemoved.
- Verify behaviour in tests.

Result:

Fewer hangs on channel creation.
@Lukasa Lukasa requested a review from artemredkin August 14, 2020 15:04
@Lukasa Lukasa merged commit 53a61d1 into apple:main Aug 14, 2020
artemredkin pushed a commit to artemredkin/swift-nio-ssh that referenced this pull request Feb 19, 2021
Motivation:

We temporarily store channel creation requests in NIOSSHHandler before
passing them to the multiplexer while we wait for the handshake to
complete. This is fine, but if for any reason we get removed from the
pipeline while we're still holding some, they must all be cancelled.

Modifications:

- Correctly cancel creation requests on handlerRemoved.
- Verify behaviour in tests.

Result:

Fewer hangs on channel creation.
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.

createChannel on inactive channel is not failed

2 participants