Real-time alert and notification platform for financial markets
Real time alerts


Client is leading stock broking company providing services like stock broking, financial products distribution, wealth management, and investment banking. They are serving customers ranging from the retail & institutional investors, corporates and High Net-worth Individuals (HNIs)

The challenge


Stock trading can become more flexible and faster if traders are notified of significant events of their choice through custom alerts and notification capability.


Trading alerts are automatic and customisable notifications sent to you whenever your specifications are triggered




For this purpose we built a solution that allows traders to set alerts for all stocks, bonds, commodities, F&O contracts, and currencies across exchanges based on user defined conditions using simple, easy-to-use operators.

Traders are then notified via email/sms and/or push notification of mobile app whenever the trigger condition meets the alert criteria


The Client has around 2,00,000 - 2,50,000 daily active users and has around 7,00,000+ users with minimum 5,000-10,000 new accounts created per month. If we consider on an average each user creating 5 custom alerts, it leads to ~30,00,000 user defined triggers (alerts) conditions might reside in database. We have to scan all the trigger conditions each time we receive a real-time stock market feed. So, for each feed across 15,000 stocks (let’s call it 'n') we need to traverse all 30,00,000 triggers (let’s call it 'm'), it will be processed in n*m times.


In PoC stage, we are solving this problem using multithreading in Java, we will be using in-memory db i.e Redis for storing triggers. The triggers will be categorized under stock symbols and user ID to prevent hotspot data and improve performance of Redis query.

We have divided it as 3 separate modules:

  1. An independent module which will store user requested (alerts) data in Redis. Using Node.js/Express based web app with ioredis to get basic frontend with rest API ready in matter of minutes.
  2. An independent module which will take feeds input and compare it with stored alerts data in Redis and when triggers condition is matched it will store results in a staging area let's say a Messaging Queue - Using Java multi-threading
  3. A separate worker which reads from MQ and calls relevant user details and Notification engine APIs to send the data to end user

Results Achieved


With this platform, you as a trader will never miss out on market movements or financial events. With the success of basic events, client is planning to extend this capability to include economic events, technical charting, research alerts and move into subscriptions-based model