2

Similar past question of mine: Azure Service Bus Queue: Can I manage/cancel scheduled messages? - accepted answer here details how to cancel scheduled messages.

I'm wondering now if there's a way to view scheduled messages using the AMQP APIs. The Azure UI (and this method https://learn.microsoft.com/en-gb/java/api/com.microsoft.azure.management.servicebus._message_count_details?view=azure-java-stable) offer message counts but I can't see anything that lets me actually view those messages.

Is this a limitation of the service bus/Azure architecture? Or is there an API that will allow it? My goal would be to build a nice UI that displays scheduled tasks, and ideally I'd like to do that without maintaining that list of tasks myself outside of Azure if possible.

Callum M
  • 1,635
  • 19
  • 27

2 Answers2

4

As of today, all messages can be peeked, but there's no way to peek those based on message status. There's an open issue on GitHub for the broker to add this feature. You can leave use-case scenario to help product team to have an idea why a feature as such would help customers.

Sean Feldman
  • 23,443
  • 7
  • 55
  • 80
  • Thanks Sean - I've put a comment on that issue. I guess since I'm not dealing with large amounts of messages just peeking client side would probably be fine. – Callum M Dec 11 '18 at 10:07
  • For a small number of messages it's ok. Would be nice to see that functionality added one day. – Sean Feldman Dec 11 '18 at 14:02
  • That's what QueueExplorer does, peeks all messages but shows only scheduled ones. Yes, it's inefficient, but if shouldn't be a big deal if you use it occasionally when something goes wrong, and not in a tight loop. Service Bus API is not very friendly for these kind of applications. – Dejan Grujić Dec 11 '18 at 17:04
1

Adding some information I found useful while reading about this.

Azure Service Bus Queues allows browsing/peeking scheduled messages. Azure Service Bus Subscriptions does not support this feature yet.

Read More View Example

hybrid
  • 1,255
  • 2
  • 17
  • 42