0
votes

Is it possible to check if a send message was dropped because the "duplicate detection"?

According to the docs:

...the message is reported as accepted (the send operation succeeds), but the newly sent message is instantly ignored and dropped.

But I want to know if it dropped or not, it that possible?

Addendum:

Ok, full picture: There is a Azure function triggered by a HTTP post that pushes the message to the topic, and the system that are posting to the function may send duplicates and I would like to log those "errors" and to return something else then a "200 OK".

It is the external system that does something wrong here, I know, but I do not have control over that system.

1
Could you further expand on your question/requirement. How are you envisioning to get this notification ? Do you expect an email when a duplicate is detected in Azure ASB ? What action do you plan to take after receiving a notification that a duplicate message was dropped in Azure service bus?Rohan
The short answer is 'no'. @Rohan asked some very good questions. I'd even extend and say "why?!". The topic is to decouple your publishers and subscribers. If you publish duplicates then you either do it purposely or it's a flaw on the publishing side. Message deduplication is intended for the subscribing side, to eliminate duplicates processing. ASB broker does what it does quite well, you can trust it. So the motive behind what you do feels off to me.Sean Feldman
Added more info to the question, but of course I did not expect a email, but since I call it programmatically it would have been nice if the result was a litte more detailed.hub

1 Answers

0
votes

According to docs,

If any new message is sent with MessageId that was logged during the time window, the message is reported as accepted (the send operation succeeds), but the newly sent message is instantly ignored and dropped.