Reputation: 346
We currently have a rails 3 app (in the process of upgrading to rails 4) and I want to start using the ActionController::Live to play with Server Sent Events for some real time updates to our users.
My question is does this new functionality work with Phusion Passenger out of the box? Everything I read is using puma, rainbows or thin. I love how easy Passenger is for our deployment, I'd even be tempted to buy the enterprise version but not if it's going to require me configuring everything to get this working. If I have to configure everything I might as well go with an open source option.
Upvotes: 3
Views: 1335
Reputation: 3962
I would like to post a Rails 4 solution i got to work seamlessly using passenger and redis..
i use ajax to response to publish events from redis you can just send data payload.
Do ensure is you rails enviornment file development.rb/production.rb
config.cache_classes = true
config.eager_load = true
You don't need puma, unicorn, goliath for SSE to work passenger serves fine.
Upvotes: 0
Reputation: 18944
Server Side Events works great on Phusion Passenger. I wrote a demo for you. Check out https://github.com/phusion/passenger-ruby-server-side-events-demo
Hongli Lai,
Phusion CTO
Phusion Passenger developer
Upvotes: 13