rabbitmq / rabbitmq-dotnet-client

RabbitMQ .NET client for .NET Standard 2.0+ and .NET 4.6.2+
https://www.rabbitmq.com/dotnet.html
Other
2.05k stars 575 forks source link

ClientArrayPool tracking is already supported by ArrayPool #1421

Closed lukebakken closed 3 months ago

lukebakken commented 7 months ago

@danielmarbach points out here that ArrayPool provides tracking capabilities so we probably don't need ClientArrayPool.

danielmarbach commented 7 months ago

I did not suggest to use MemoryPool instead in the comment linked. My point was that the code that previously used ArrayPool could be instrumented by leveraging the event source. As far as I understand the ClientArrayPool has tracking code.

I've also made another comment about the larger problem probably not being addressed since disposing the buffers was essentially just moved to a different path.

lukebakken commented 7 months ago

My point was that the code that previously used ArrayPool could be instrumented by leveraging the event source. As far as I understand the ClientArrayPool has tracking code.

OK, I see. I will adjust this issue to reflect that.

I have addressed the "larger problem". Thanks for pointing that out!