-1

I want to develop a web file manager based on Rails 4.2 (Ruby 2.1.0) with websockets.

  • Websocket-rails seems nice, but is dead.
  • em-websocket lacks documentation (or if you have a link it will be great) and is not fully open source compliant.

What is the best way to use websocket with rails?

sawa
  • 165,429
  • 45
  • 277
  • 381
Olivier B.
  • 97
  • 1
  • 2
  • 11

2 Answers2

0

Take a look at faye-websocket. Here is a nice railscasts tutorial.

Masudul
  • 21,823
  • 5
  • 43
  • 58
0

Take a look at the Plezi framework.

The advantage over Faye is that Faye requires you to handle your Redis broadcasting logic yourself, whereas Plezi is a framework, which handles the Redis logic for you and lets you run both your Plezi websockets app and your Rails app on the same port on the same server.

Plezi is also easily scalable when using Redis, as it can run all it's broadcasting and unicasting API through Redis and you don't need to do anything except point it to your Redis server.

As stated in the documentation, You just include your Plezi code in your Rails app as middleware. Easy.

Myst
  • 18,516
  • 2
  • 45
  • 67