Azure / azure-amqp

AMQP C# library
Other
94 stars 70 forks source link

Client receivers draining credit should receive an acknowledging flow frame #219

Closed jhendrixMSFT closed 2 years ago

jhendrixMSFT commented 2 years ago

When a receiver sends a flow frame with drain: true, it would be ideal if the broker would send an acknowledging flow frame with drain: true set so we know the peer received our drain request.

The spec says this is a SHOULD, so while the existing behavior is technically correct, sending the ack would be an improvement and consistent with service bus.

xinchen10 commented 2 years ago

Which broker is this issue for?

jhendrixMSFT commented 2 years ago

This was observed using the test broker. Does this imply that ack'ing a drain is handled at the broker level, not the protocol level?

xinchen10 commented 2 years ago

Broker has to implement the credit management required by the drain behavior. Currently the test broker does not support it.

xinchen10 commented 2 years ago

Added this support to the test broker.

jhendrixMSFT commented 2 years ago

https://github.com/Azure/azure-amqp/commit/53efc8a94ee1b173c42bbb08409703e9dffa6101