You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mina.apache.org by GitBox <gi...@apache.org> on 2022/04/15 18:05:08 UTC

[GitHub] [mina-sshd] tomaswolf commented on pull request #217: [SSHD-966] Flush pending packets asynchronously at end of KEX

tomaswolf commented on PR #217:
URL: https://github.com/apache/mina-sshd/pull/217#issuecomment-1100267827

   @lgoldstein, @gnodet: this is my take on SSHD-966. The change factors out into a separate per-session object `KeyExchangeMessageHandler` all the logic about which packets to enqueue during KEX and how to flush them. Locally, I have green test runs, with a few flaky tests when Netty is used, but (a) I always have them, also without this change, and (b) the failures occur on connect() and are unrelated to KEX.
   
   This resolves the race condition in `AbstractSession.writePacket()` I mentioned in SSHD-966, and avoids the lock inversion that could occur between the `ChannelOutputStream` and the flushing if some error occurred an the session was closed while flushing.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@mina.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@mina.apache.org
For additional commands, e-mail: dev-help@mina.apache.org