Closed CeeSharpDev closed 2 years ago
Hi @CeeSharpDev
When you call Send
on SenderLink
it will synchronously block until the other party sends ack (or throw TimeoutException if no ack received). That's the default behavior, for the mentioned overload.
Please take a look here for more details. --> https://github.com/Azure/amqpnetlite/blob/master/src/SenderLink.cs#L110
Hi @Havret
so when an message is received by the broker, does SenderLink.LinkState = Accepted
mean that broker has accepted and Acknowledged the message?
No, when Send
returns it means that the broker has ack'ed the message. That's the default behaviour.
Okay, understood now. Thank you @Havret for your quick reply. 👍 :)
To start with, I am pretty new to Amqp. I have my Solace broker running. And I am using Amqpnetlite Library to establish connection to Solace Amqp. I am able to establish connection and also sending messages.
My objective is to achieve Guaranteed Transmission, which means I would like to see an Acknowledgement once the message is successfully published to the Queue. And for which as per documentation I found "http://azure.github.io/amqpnetlite/api/Amqp.SenderLink.html#implements" a method
Send(Message, TimeSpan)
.I am still unable to understand, how would I be able to see the Acknowledgement, in order to confirm the message was published and proceed with next message for publishing.
Please find below a simple code snippet I am currently following up for Publishing Message To Queue
I would really appreciae, if someone could guide me here to proceed further.