Monitoring silence in your Azure Service Bus Queues
Are you not aware of a situation where no messages are flowing in your Queue/Topic?
It is very simple to configure and get alerted to this situation with Serverless360 Data Monitoring.
The flow of messages in your resources is of prime importance when you use Queues or Topic Subscription in your integration architecture. Messages flow at a different rate in the system. Sometimes, publishers generate messages at a faster rate, there may be an orchestration or workflow processing a batch of messages that push them back to the system. There will be a flurry of messages, during certain period there will be a huge volume of messages passing through and at times there are no messages at all. Whatever be the case, setting up appropriate monitoring will help to watch your system for any abnormalities. For instance, if there are any unexpected scenario to occur, you need to be notified so that you can take a look at the respective resources and take corrective actions in your system.
In this section, let us discuss a scenario where you need to be notified when there is no message flowing through your resource either a Queue or a Topic for a specific period of time, in other words, if your Queue is silent for, say 15 minutes. This may be because your publishing applications are not sending messages to the resource or there is a different problem that you will fix as soon as you come to know about this situation.
Serverless360 Data Monitoring
This is exactly the reason, we have built Serverless360 Data Monitoring. Resources can be monitored based on certain metrics within a specified time window. This will help you to check if your resource or system keeps up with your business SLA.
In Serverless360, you can create a data monitor to check the following metrics:
Incoming Messages – set Warning < 5 & Error < 1
Outgoing Messages – set Warning < 5 & Error < 1
And check if there is any flow of messages (inbound or outbound) for every 15 minutes.
Based on the above configuration, Serverless360 will monitor the ingress and egress of messages to your queue every 15 minutes and if there are less than 5 messages flowing, it will forward a warning alert and if there are no messages moved in the 15-minute window, it will forward an error alert.
For more reading on Serverless360 Data Monitoring capability, refer to this document.
## Monitoring Azure Service Bus Queue availability
### Are you not aware of availability of your Queue ?
Threshold monitor and Data Monitoring capabilities in our platform will help you to configure and get alerted whenever the queue is unavailable in your Azure Subscription.
The queue might become unavailable in any of the following scenarios. Consider an Azure Service Bus queue which is already associated to a Serverless360 Composite Application and being monitored by a threshold monitor for the expected status.
1) When the queue is in Disabled / Send disabled / Receive disabled state
If Azure Service Bus Queue state is not ‘Active’ the queue will be unavailable for certain operations. When the state is –
- ‘Disabled’ - the queue will not be available for message send or receive operations.
- ‘Send Disabled’ - sending messages to the queue is not possible.
- ‘Receive Disabled’ - receiving messages from the queue, other than peek lock, is not possible.
2) When the queue is removed from the Service Bus namespace
If the resource is removed from the Azure Subscription, then the status of the queue will be ‘Unknown’ and will not be available for any operations in the client applications. Serverless360 will mention this resource as ‘orphaned’ in the notification.
3) When the subscription in which the queue is present is disabled
If the Azure subscription in which the queue is present is disabled, the queue will be detected to be in status ‘Unknown’. Serverless360 will mention this resource as ‘orphaned’ in the notification.
Serverless360 can monitor Azure Service Bus Queue state and notify on the expected state not being met. Threshold monitor can be configured to get notified on the above 3 scenarios.
A notification forwarded due to unavailability of Queue will look like this:
4) When there is a temporary unavailability due to outage
This will raise a situation for Server Errors which can be monitored in Serverless360 using Data monitor.
5) When the Quota on the Queue has exceeded
When the queue already has messages that occupy its total size, sending any more messages to the queue is not possible. Any more attempts to send message to the queue will result in User error. Monitoring for User Error can check for queue availability in this scenario.
You can monitor your queue for number of Server / User Errors that occurred over a period i.e. say every 15-minute window.
Based on the above configuration, you will receive warning alert if the number of errors is less than 5 in the last 15 minutes and error alert when the errors are greater than 5. This way you can receive alerts when there are errors in your resources. In this example, We used User Errors to explain the concept as We cannot create Server Errors. Server Errors can happen when there is a challenge at infrastructure.
Refer Data Monitoring in product documentation for more details.