Installation and Setup
Getting started is quick and painless.
websocket-railsgem to your Gemfile and run the
Run the installation generator:
rails g websocket_rails:install
Create a new [WebsocketRails Controller](WebsocketRails Controllers) and direct events to it using the Event Router.
Remove the Rack::Lock middleware by adding the following line to your
- Start the web server:
The generator will create a new event route file located at
config/events.rb. You can use this file to direct
incoming events to controller actions. More information on using the
event router is located in the Event Router Wiki. An initialization file will be created in
config/initializers/websocket_rails.rb which can be used to configure WebsocketRails.
Non EventMachine Based Web Servers (Phusion Passenger Etc.)
If you are using a non-eventmachine based production web server such as Phusion Passenger, you will need to use the standalone server mode. Refer to the wiki for more information.
Upgrading From Prior Versions
If you are upgrading from an older version of the gem, check out the Configuration Wiki to see the new options available.
When you get error with socket connection
This pull request would help you.
Change gemfile as following
gem 'websocket-rails', github: 'recurser/websocket-rails', branch: 'bugfix/388-latest-faye-websocket'