1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
Commit graph

18 commits

Author SHA1 Message Date
Pratik Naik
37fe48928e Rename Subscription#reject! to Subscription#reject as there's only one version of the method 2015-11-05 09:37:15 -06:00
Pratik Naik
cb4ef80f20 Merge branch 'master' into subscription-rejection 2015-11-04 17:22:48 -06:00
Rafael Mendonça França
9f1938d9c1 Merge pull request #69 from mieko/callbacks
Use ActiveSupport::Callbacks for Channel subscription callbacks.
2015-10-23 20:15:40 -02:00
Pratik Naik
0ce0cf0c04 Allow rejecting subscriptions from the channel 2015-10-21 13:47:48 -05:00
Pratik Naik
904b83b9c3 Fix the error message in tests 2015-10-19 15:28:26 -05:00
Pratik Naik
a02e5f418b Better test name 2015-10-19 15:27:43 -05:00
Pratik Naik
506d84c157 Make sure the subscription confirmaion is only sent out once 2015-10-19 15:14:22 -05:00
Pratik Naik
06b59451ff Fix an error message in the subscription tests 2015-10-16 21:13:48 -05:00
Pratik Naik
84b1f0a3e6 Send subscription confirmation from server to the client to avoid race conditions.
Without this, it's very easy to send messages over a subscription even before the
redis pubsub has been fully initialized.

Now we delay calling the subscription#connected method on the client side until we
receive a subscription confirmation message from the server.
2015-10-16 21:11:21 -05:00
Pratik Naik
df5a32dfbc Fix stream tests 2015-10-16 18:19:35 -05:00
Jeremy Daer
4d6f1b0cbe Shush some low-hanging Ruby warnings 2015-10-16 00:32:46 -07:00
Pratik Naik
ee16ca8990 Run connection tests in EM loop 2015-10-15 21:11:49 -05:00
Mike A. Owens
cf426a7ee6 Use ActiveSupport::Callbacks for Channel subscription callbacks.
* Rely on AS::Callbacks for callback handling.
 * Add before_subscribe, after_subscribe, before_unsubscribe and
   after_unsubscribe convenience methods
 * alias on_subscribe and on_unsubscribe to after_subscribe and
   after_unsubscribe, respectively.
 * Remove `subscribed` and `unsubscribed` from the callback chain:
   these methods are now executed as the subject of the callbacks.
 * Update portions of ActionCable to use the more specific
   callback names.
2015-08-24 13:46:41 -04:00
Kasper Timm Hansen
ae61460cb2 Merge pull request #34 from lsylvester/add-broadcast_to-and-stream_for-methods-to-channel
add broadcast_to and stream_for methods as per #26
2015-07-29 21:57:20 +02:00
Lachlan Sylvester
5954fd1e0a add broadcast_to and stream_for methods as per #26 2015-07-28 17:31:37 +10:00
Cristian Bica
a97a1fc745 Improve channel actions dispatcher to allow inheritance/mixins
Fixes #14
2015-07-23 15:00:30 +03:00
Pratik Naik
e1da6814b4 Always load all the stub files 2015-07-13 11:30:52 -05:00
Pratik Naik
1af531dcf7 Add some more tests 2015-07-12 11:44:56 -05:00