I would like to know more about the delivery process of push notifications. How did you implement the workflow of these notifications from the PRTG core server to my mobile device? What are the components which have to interact while sending a push message? What role does the PRTG cloud have in this process?
This article applies to PRTG Network Monitor 15.4.20 or later
The PRTG Cloud and the Workflow of Push Notifications
With PRTG version 15.4.20 or later and the apps PRTG for Android (version 14.3.2 or later) or PRTG for iOS (version 14.3.6 or later), you can use the notification type Push Notifications for your network monitoring. The article How can I use push notifications with PRTG? explains how to setup and work with push notifications.
As you can see in the article mentioned above, you do not have to do much on your own to receive push messages on your mobile device and use them as notifications from PRTG. We tried to keep this approach as simple as possible for you so that you can use your valuable time to take care of your network rather than spend it on potentially complicated configuration steps.
Of course, the underlying approach of sending push notifications from your PRTG server to your smartphone is a bit more complex. There are several components which have to interact to process push notifications and send them to the correct target device.
The following sketch illustrates the push workflow, involved components, and how they interact until you receive the notification message on your mobile device:
You can see two workflow sequences in the diagram which PRTG runs through for push messages:
- The push service registration process to register your mobile device for push notifications,
- and the regular delivery process that describes the steps to send a notification as push message to your target device through the PRTG cloud.
Note: The PRTG server must have access to the internet to reach the PRTG Cloud at https://api.prtgcloud.com:443 . If you use Cloud HTTP and Cloud Ping sensors, this also applies to the system(s) running the PRTG probe(s) with these sensors on.
Note: PRTG versions previous to 15.4.20 do not support cloud features anymore because we changed the cloud infrastructure with this version. If you run a previous PRTG version, please update your PRTG server to use push notifications and other PRTG cloud features like the cloud sensors.
Push Service Registration Process
There are three steps necessary for PRTG to register your device for push messages:
- When you activate push messages in your PRTG app as described in section First Time Setup in this article, the app requests a token from the cloud of your mobile device's platform (which is Google or Apple) to register with this cloud. This token is a unique identifier for your mobile device so that the respective cloud service can send the push message to the correct device. The used messaging clouds are:
- The messaging cloud of Google, Apple, or Microsoft assigns the token to your mobile device to uniquely identify it later.
- The PRTG app sends this unique token to your PRTG core server. This creates a new entry in your PRTG web interface in the Notification Contacts of the user account you connected with. Your mobile device will appear with its name and the token in the contacts list.
Click here to enlarge.
- If you register a mobile device for the first time and the registration process is completed successfully, you will receive a confirming push message.
This process is run for each user account that uses push notifications. Because the tokens that the PRTG mobile apps get from their respective platform cloud services expire from time to time, this process is run regularly to replace the old tokens with new ones. So it is not possible to add the tokens by hand—the apps need to be able to connect to the PRTG server in order for push notifications to be reliable.
Regular Delivery Process of Push Messages
Once you have registered your mobile device for push messages, you can create push notifications and set up corresponding triggers in PRTG. Triggered push notifications—for example, if a hard disk on your computer runs out of space—will appear in the notification area of your mobile device immediately.
For this, the notification has to run through several steps:
- When a push notification is triggered by a sensor in PRTG, the core server sends the notification with the defined information (“Message” in the push notification settings) about this incident to the PRTG Cloud.
- The PRTG Cloud checks the license key of your PRTG server and processes the notification accordingly. For example, it applies the flood protection mechanism to ensure that your mobile device will not be flooded with too many messages. The PRTG cloud converts the notification into a push message with all necessary information, including the token to identify the correct target device, and sends the message to Amazon SNS (Simple Notification Service).
- Like the PRTG cloud, Amazon SNS checks several properties of the message, queues it if necessary so that it will not get lost, and automatically converts it into the correct format for the vendor specific messaging cloud. Amazon SNS ensures that the push message is always passed along in the correct format, provides high availability, and delivers messages very fast.
- The respective messaging cloud uses the unique token of the push message to identify the destination and pushes it to your Android or iOS device where it appears in the notification area immediately.
Although the regular delivery process for push notifications involves several steps and components, a push notification will usually appear on your mobile device within moments after being triggered in PRTG. With the PRTG cloud as a service, you can easily use push notifications without wondering how to connect your PRTG core server to the Google or Apple messaging clouds.
We have done everything to ensure a failsafe, reliable service for you. However, because unexpected things can always happen in the IT (server outages, network outages which disrupt connections between the involved components, failures on your mobile device), we strongly recommend you to always create at least two notifications with different delivery methods for your critical systems!
For more information, please see also the article Is there an FAQ for push notifications?
PRTG Cloud Status
Stay informed about the status of the PRTG cloud on Twitter and follow @PRTGCloudStatus!