Skip to content

Optimized incoming bytes queue. Release lock asap.#800

Closed
SwarajKetan wants to merge 1 commit intosshnet:developfrom
SwarajKetan:develop
Closed

Optimized incoming bytes queue. Release lock asap.#800
SwarajKetan wants to merge 1 commit intosshnet:developfrom
SwarajKetan:develop

Conversation

@SwarajKetan
Copy link

Current incoming queue keeps the bytes. It is expensive operation since the OnDataReceived event gets the data in form of byte[]. If we read the bytes from array and enqueue them into incoming queue, it will hold the lock on incoming queue for long. This in-turn blocks the read operation from the incoming queue. Hence, the change from Queue -> Queue<byte[]> improves performance.

@jscarle
Copy link
Contributor

jscarle commented Feb 13, 2024

@IgorMilavec @WojciechNagorski This can be closed as ShellStream has changed too much since this PR.

@WojciechNagorski WojciechNagorski added this to the 2024.0.0 milestone Feb 22, 2024
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.

4 participants