amqp091-go
amqp091-go copied to clipboard
Remove deprecated API functions
Follow-up to https://github.com/rabbitmq/amqp091-go/pull/96
Version 2 should remove deprecated API functions and "clean up" those that are left, perhaps coming up with a better name than PublishWithDeferredConfirm
.
To be honest if you're publishing without confirmations the function should be called PublishButDontComplainWhenYouLoseData
Also note that context is no longer used in publishing (#195, discussion).
I've been thinking of removing the deprecated functions and removing the *WithContext
prefix, so that we go back to Publish()
taking context as first argument. Same story for Consume
, make the function that takes context the only one and remove the one that doesn't.
Since we are going 2.0, we could take this change to make these breaking changes.
Regarding #195, I think there is a point for using contexts in Publish
, as it should not send the message if the context is cancelled. I don't think we can interrupt or cancel an RPC to the server once we sent the publish frame.