This seems to be related to MuxIO, since I couldn't replicate when UseConnectionPooling was false. I noticed it on master, so not sure if its a regression after 2.4.4 or before - will update ticket once i know more.
Steps to reproduce:
- Run a load against a 2 node cluster using UpsertAsync
- Swap out the EP node
- Swap in the node previously swapped out
- You will notice that the client never recovers and begins to timeout more and more operations and memory consumption will go up (slowly)
Possibly related: SocketAsyncState contains a MemoryStream reference which is never disposed! This is likely the cause of memory consumption.