Azure / azure-amqp

AMQP C# library
Other
94 stars 70 forks source link

Remove allocations for AmqpMap enumeration by storing the Dictionary … #247

Closed Stabzs closed 1 year ago

Stabzs commented 1 year ago

Addresses https://github.com/Azure/azure-amqp/issues/246

Remove allocations for AmqpMap enumeration by storing the Dictionary as a concrete type and adding an explicit concrete GetEnumerator method.

Reduce allocations for AmqpBufferedMessage by omitting ToArray() call when we already have a concrete list.

Reduce allocations for AmqpDataMessage by presizing segmentList capacity increases when dataList implements ICollection.

Stabzs commented 1 year ago

@microsoft-github-policy-service agree