Scala + Play + Akka. Is there a need for Backbone.js?

Viewed 1518

My backend is in Postgres. I'm using Scala to build APIs of it.

Everytime there is a change in the database, I want my chrome extension to be notified. I've a few questions regarding this:

  1. Should I implement websockets here or do long polling?
  2. If web-sockets, are there any good examples of how do I do it using scala + play + Akka and javascript?
  3. I believe that I've to implement something called as an observer pattern that notifies my chrome extension if there is any change in data. Is there any other pattern that I should follow to get such a thing done with the minimum DB over-head.
  4. Should I use Redis or RabbitMQ to deal with this particular notification part of things?
1 Answers
Related