From de2afdc457d63ee628b5cac4e7bb73812e016e38 Mon Sep 17 00:00:00 2001 From: Yauheni Dakuka Date: Fri, 6 Oct 2017 09:02:56 +0300 Subject: Cosmetic fixes [ci skip] --- guides/source/action_cable_overview.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'guides/source/action_cable_overview.md') diff --git a/guides/source/action_cable_overview.md b/guides/source/action_cable_overview.md index 31151e0329..dd16ba3932 100644 --- a/guides/source/action_cable_overview.md +++ b/guides/source/action_cable_overview.md @@ -557,7 +557,7 @@ The async adapter is intended for development/testing and should not be used in Action Cable contains two Redis adapters: "normal" Redis and Evented Redis. Both of the adapters require users to provide a URL pointing to the Redis server. -Additionally, a channel_prefix may be provided to avoid channel name collisions +Additionally, a `channel_prefix` may be provided to avoid channel name collisions when using the same Redis server for multiple applications. See the [Redis PubSub documentation](https://redis.io/topics/pubsub#database-amp-scoping) for more details. ##### PostgreSQL Adapter -- cgit v1.2.3 From 27394404390348c894ee9a527d786031ac0d5794 Mon Sep 17 00:00:00 2001 From: bogdanvlviv Date: Mon, 23 Oct 2017 21:18:57 +0300 Subject: Remove mention about Evented Redis [ci skip] Evented Redis is removed from Rails. See #30945 --- guides/source/action_cable_overview.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'guides/source/action_cable_overview.md') diff --git a/guides/source/action_cable_overview.md b/guides/source/action_cable_overview.md index dd16ba3932..6ac6792e26 100644 --- a/guides/source/action_cable_overview.md +++ b/guides/source/action_cable_overview.md @@ -555,8 +555,7 @@ The async adapter is intended for development/testing and should not be used in ##### Redis Adapter -Action Cable contains two Redis adapters: "normal" Redis and Evented Redis. Both -of the adapters require users to provide a URL pointing to the Redis server. +The Redis adapter requires users to provide a URL pointing to the Redis server. Additionally, a `channel_prefix` may be provided to avoid channel name collisions when using the same Redis server for multiple applications. See the [Redis PubSub documentation](https://redis.io/topics/pubsub#database-amp-scoping) for more details. -- cgit v1.2.3 From 3b66804c81c0698e96ceebd7dd02fa0dc4c54e26 Mon Sep 17 00:00:00 2001 From: "yuuji.yaginuma" Date: Thu, 26 Oct 2017 14:32:23 +0900 Subject: Remove mention about Evented Redis [ci skip] Evented Redis adapter was removed in 48766e32d31651606b9f68a16015ad05c3b0de2c. --- guides/source/action_cable_overview.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'guides/source/action_cable_overview.md') diff --git a/guides/source/action_cable_overview.md b/guides/source/action_cable_overview.md index 6ac6792e26..57403a4bf9 100644 --- a/guides/source/action_cable_overview.md +++ b/guides/source/action_cable_overview.md @@ -668,8 +668,8 @@ authentication. You can see one way of doing that with Devise in this [article]( ## Dependencies Action Cable provides a subscription adapter interface to process its -pubsub internals. By default, asynchronous, inline, PostgreSQL, evented -Redis, and non-evented Redis adapters are included. The default adapter +pubsub internals. By default, asynchronous, inline, PostgreSQL, and Redis +adapters are included. The default adapter in new Rails applications is the asynchronous (`async`) adapter. The Ruby side of things is built on top of [websocket-driver](https://github.com/faye/websocket-driver-ruby), -- cgit v1.2.3 From d5eb8f23c8543ae3c8cff6aefdbb6bbcf2f28128 Mon Sep 17 00:00:00 2001 From: Francis Go Date: Wed, 22 Nov 2017 16:33:28 +0000 Subject: Update Action Cable Overview Guide [ci skip] --- guides/source/action_cable_overview.md | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'guides/source/action_cable_overview.md') diff --git a/guides/source/action_cable_overview.md b/guides/source/action_cable_overview.md index 57403a4bf9..1a86b1fcbb 100644 --- a/guides/source/action_cable_overview.md +++ b/guides/source/action_cable_overview.md @@ -1,12 +1,12 @@ Action Cable Overview ===================== -In this guide you will learn how Action Cable works and how to use WebSockets to +In this guide, you will learn how Action Cable works and how to use WebSockets to incorporate real-time features into your Rails application. After reading this guide, you will know: -* What Action Cable is and its integration on backend and frontend +* What Action Cable is and its integration backend and frontend * How to setup Action Cable * How to setup channels * Deployment and Architecture setup for running Action Cable @@ -129,7 +129,7 @@ subscriptions based on an identifier sent by the cable consumer. # app/channels/chat_channel.rb class ChatChannel < ApplicationCable::Channel # Called when the consumer has successfully - # become a subscriber of this channel. + # become a subscriber to this channel. def subscribed end end @@ -225,7 +225,7 @@ A *broadcasting* is a pub/sub link where anything transmitted by a publisher is routed directly to the channel subscribers who are streaming that named broadcasting. Each channel can be streaming zero or more broadcastings. -Broadcastings are purely an online queue and time dependent. If a consumer is +Broadcastings are purely an online queue and time-dependent. If a consumer is not streaming (subscribed to a given channel), they'll not get the broadcast should they connect later. @@ -515,8 +515,8 @@ user. For a user with an ID of 1, the broadcasting name would be The channel has been instructed to stream everything that arrives at `web_notifications:1` directly to the client by invoking the `received` callback. The data passed as argument is the hash sent as the second parameter -to the server-side broadcast call, JSON encoded for the trip across the wire, -and unpacked for the data argument arriving to `received`. +to the server-side broadcast call, JSON encoded for the trip across the wire +and unpacked for the data argument arriving as `received`. ### More Complete Examples @@ -569,7 +569,7 @@ This may change in the future. [#27214](https://github.com/rails/rails/issues/27 Action Cable will only accept requests from specified origins, which are passed to the server config as an array. The origins can be instances of -strings or regular expressions, against which a check for match will be performed. +strings or regular expressions, against which a check for the match will be performed. ```ruby config.action_cable.allowed_request_origins = ['http://rubyonrails.com', %r{http://ruby.*}] @@ -592,7 +592,7 @@ environment configuration files. ### Other Configurations -The other common option to configure, is the log tags applied to the +The other common option to configure is the log tags applied to the per-connection logger. Here's an example that uses the user account id if available, else "no-account" while tagging: @@ -607,7 +607,7 @@ config.action_cable.log_tags = [ For a full list of all configuration options, see the `ActionCable::Server::Configuration` class. -Also note that your server must provide at least the same number of database +Also, note that your server must provide at least the same number of database connections as you have workers. The default worker pool size is set to 4, so that means you have to make at least that available. You can change that in `config/database.yml` through the `pool` attribute. -- cgit v1.2.3