aboutsummaryrefslogtreecommitdiffstats
path: root/actioncable/lib/action_cable/connection/client_socket.rb
Commit message (Collapse)AuthorAgeFilesLines
* Merge pull request #24224 from danielrhodes/actioncable-websocket-protocolsJeremy Daer2016-04-051-2/+6
|\ | | | | | | ActionCable protocol negotiation
| * Added protocol negotiationDaniel Rhodes2016-04-051-2/+6
| | | | | | | | | | | | | | | | | | This is primarily for backwards compatibility for when or if the protocol is changed in future versions. If the server fails to respond with an acceptable protocol, the client disconnects and disables the monitor.
* | Gracefully handle disconnected clientsJeremy Daer2016-03-201-0/+2
|/ | | | | | | | We'll get `Errno::ECONNRESET` if the client forcibly disconnected. Just close the socket rather than raising the exception. Handle other errors in `ClientSocket#write`, too, mirroring the Faye error handling which swallows all `StandardError` on write.
* Support faye-websocket + EventMachine as an optionMatthew Draper2016-03-021-5/+5
|
* The async.callback call should live with the hijackMatthew Draper2016-02-261-4/+5
| | | | If we're deferring one, we should defer the other too.
* Only hijack Rack socket when first neededJon Moss2016-02-241-0/+1
| | | | Fixes #23471
* Fix `unsubscribed` server side behaviorJon Moss2016-02-181-5/+2
| | | | | | | | | | | | | Before this commit, the `unsubscribed` callbacks in Action Cable server side channels were never called. This is because when a WebSocket "goodbye" message was sent from the client, the Action Cable server didn't properly clean up after the now closed WebSocket. This means that memory could possibly skyrocket with this behavior, since part of this commit is to properly remove closed subscriptions from the global subscriptions hash. Say you have 10,000 users currently connected, and then all 10,000 disconnect -- before this patch, Action Cable would still hold onto information (and Ruby objects!) for all of these now dead connections.
* Fix arguments to on_closeMatthew Draper2016-01-301-4/+2
|
* Revert "Revert "Eliminate the EventMachine dependency""Matthew Draper2016-01-301-0/+152
|
* Revert "Eliminate the EventMachine dependency"David Heinemeier Hansson2016-01-271-152/+0
|
* Import the relevant portions of faye-websocketMatthew Draper2016-01-241-0/+152
(as adapted to use concurrent-ruby / nio4r instead of eventmachine)