Email Alerting System based on User preferences
Any ideas around desig开发者_如何学编程ning and/or implementing Java based Email alerting system (similar to RSS) which would let users pick the frequency, application type, email content and based on their preferences the alerting system would call a program to generate emails. The program would get the data from the database and populate it in the email body. Now, the question really is how to tie up the two pieces together i.e. based on the user preferences trigger the program for email generation.
Seems a pretty simple set of requirements
Scheduled job (cron, DBMS_SCHEDULER, whatever) runs every x minutes.
- It picks out any user with a 'next_send_date' in the the next x minutes.
- It picks out what to send them
- It sends the email
- It reschedules their 'next_send_date' based on preferences
- Go to next user.
which of those looks like it is difficult ?
That's what I made out of it: https://github.com/molindo/molindo-notify
Shockingly undocumented code though. If you're interested, just let me know. I'll try to come up with some docs.
精彩评论