Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Best solution architecture for user notifications in Java/Grails environment?

I am building a community website using Grails and I want to implement user notifications exactly like stackoverflow.com. For instance, user will get notified for new events ('You have new comments', 'one of your favorite has changed'...) either by email or in his mailbox anytime he returns to the website.

I suppose that this is a common problem and I'd like to hear what easy solution do you advice for implementing the back-end in Grails realm. For instance, is Java Message Service a recommended solution for this?

Thank you.

like image 836
fabien7474 Avatar asked Oct 28 '10 09:10

fabien7474


1 Answers

IMHO no. Java Message Service is basically to perform asynchronous or queued operations.

You just need a user messaging system and notification. I'm not aware of any plugin that could do it out of the box.

I suggest you to implement your own Message domain POGO bound to your user model with a markAsRead flag.

If you want to integrate this with email you can use JMS to decouple user navigation and email/sending. This is particularly useful if you have an high traffic website/webapp

like image 69
Sammyrulez Avatar answered Sep 29 '22 10:09

Sammyrulez