I want to solve one of my design problem where I am getting several events data but for one kind of data I do not want to store the event as soon as it happens instead I want to wait for 10 minutes to let them happen those event but want to keep the number of event counts happening so that once the interval of 10 minutes reaches I can store the count with the event cumulatively which will reduce the number of operation being involve with database.
For example Let's say I have three events namely EV1, EV2 and EV3. Event EV3 happens in my application in very large volume other two events are less frequent. But I am not concerns to capture every trigger of the event but I am interested to know how many times that event (EV3) happened. So thinking to capture the EV3 count in 10 minute of interval by storing the counts somewhere on the fly and dump the same in every 10 minutes.
Please suggest a good and simple design for it which can be used in Java, Thanks in advance.
Aucun commentaire:
Enregistrer un commentaire