A notification system has become a mandatory feature os any system that helps touch it users, collect analytics data, etc. It's more than a mobile push and there are some different types of notification formats like push, SMS, email and software badge (not covered here).
In this article, we will surf on Notification System Design for Push, SMS and email formats in near real time, average of 10 million of notifications per day triggered by a secure API Endpoint respecting an unsubscribe list control.
Notification Types
1. iOS Push
Notification for iOS Devices.
A provider sends notifications do Apple Push Notification Service, a remote service provided by Apple do push notifications do iOS devies.
2. Android Push
Notification for Android Devices.
The android notification is similar of IOS notification flow, but, instead using de APNs we will use Firebase Cloud Messaging do tens android push notifications.
3. SMS Message
Notification using SMS Message.
Same above, but, using a SMS Service provider like Twilio. Some providers like Twilio has features to send message using WhatsApp telephony and mail marketing.
4. Email Message
Notification using Email Message.
Same above, but, using a email service provider like Sendgrid.
Notification System Design Architecture
Important to say, it's a high-level design and we will have a lot of not covered details in this article when we focus on each point of this picture.
External software sends JSON message through https with message data, like address, type, message, etc.
Rate limiter validate internal rules to protect system overload and security issues.
Notification Service receives the message, deliver to correct message queue and writes some log to data store over a Data Cache cluster.
Some workers consumes the messages from queue and connect with third part software to send a message to defined device type ou message format.
Third part software calls back using Web Hooks to give status and analytics information about message.
More workers running gets these informations and stores on data store layer.
Status and analytics data are available for Notification Status & Analytics Service giving these data to external Service back.
Using these system design the software we gain the following benefits:
Reliability: mechanisms to minimize the failure rate and SPOF.
Security: running over https using AppKey/appSecret pair to ensure only authorized users can send messages.
Tracking and Monitoring: logs, status and analytics data are stored.
Rate Limiting: protect system overload, unexpected burst and security issues.
This design works very well and should be replicated in other regions to increase the SLA, inserting new components like Load balancers, Big IPs, etc.
Features of Notification System:
1. Triggering Notifications:
In this, notification engine will let you trigger notifications for various events (sign-ups, new purchases, empty carts etc.) and channels (emails, SMS etc.). Though how many channels and what type of triggers it will support depends on the notification engine you have opted for. A quality notification system allows you to trigger multi-channel, event-based notifications to your audience.
2. Managing Notification and Audience Lists:
Most of the Notification system comes with Managing Notification and Audience Lists where there are frequent requirements to add, edit and manage notification, Manage Audience Lists etc.
3. Mass Notification:
This includes triggering or creating notification in a notification management system. With the mass notifications feature one can send a bulk number of notifications to a large audience.
4. Analytics:
The best of the notification engines are designed to provide timely analytics. Such analytical reports give you insights on the delivery of your notifications, user actions, and others. This feature not only makes a notification engine more efficient but also helps you further in understanding your audience and serve them better.
5. Seamless Integration:
Seamless integration implies smooth & fast integration of the notification system with your online platform as well as with the existing third party solutions. Such third party solutions may include other notification management systems, other products, solutions etc. Though this is a hugely sought-after feature, not every notification engine is equipped with this.
Resource: Medium (Leandro Franchi), muvi
The Tech Platform
Comments