Closed kerbong closed 2 years ago
"ws://localhost:50051/cable"
This: 50051 is the gRPC port, WebSocket server is listening on :8080 by default (check the output of the anycable-go
command).
@palkan Thanks your fast response!! i tried your advise and then another googling advises... and then things changes..
javascript/channels/consumer.js ` import { createConsumer } from "@rails/actioncable"
export default createConsumer('wss://studying-app-iloagg.run.goorm.io:8080/cable') ` and...
Chrome console log changed !!!
"action_cable.js:259 WebSocket connection to 'wss://studying-app-iloagg.run.goorm.io:8080/cable' failed: WebSocket is closed before the connection is established."
======
how can i know anycable-go installed correctly ?? when i write 'anycable-go' in my terminal, it shows "can't find command... "
if there was not anycable-go... then where can i fix the code the upper one..
=== sudo apt-get install golang-go sudo apt update sudo apt install golang-go go get -u -f github.com/anycable/anycable-go/cmd/anycable-go
thanks again!!
how can i know anycable-go installed correctly ?? when i write 'anycable-go' in my terminal, it shows "can't find command... "
What is the output of the go get -u -f github.com/anycable/anycable-go/cmd/anycable-go
command?
Anyway, I'd suggest using pre-built binaries (see Releases) instead of building from source.
when i write "go get -u -f github.com/anycable/anycable-go/cmd/anycable-go" in terminal
go get: -f flag is a no-op when using modules go: downloading google.golang.org/genproto v0.0.0-20210722135532-667f2b7c528f
... and nothing happen.
====
but... there is something changed !!!
i followed getting started from your anycable documents (https://docs.anycable.io/rails/getting_started)
and now, if i put " anycable-go --host=localhost --port=8080 " in terminal or "anycable-go"
=== root@goorm:/workspace/studying_app# anycable-go --host=localhost --port=8080 INFO 2021-07-23T03:37:09.636Z context=main Starting AnyCable 1.1.2-bbf4cae (pid: 745, open file limit: 1024) INFO 2021-07-23T03:37:09.640Z context=main Handle WebSocket connections at http://localhost:8080/cable INFO 2021-07-23T03:37:09.640Z context=main Handle health connections at http://localhost:8080/health WARN 2021-07-23T03:37:09.643Z context=pubsub Redis connection failed: dial tcp 127.0.0.1:6379: connect: connection refused INFO 2021-07-23T03:37:09.644Z context=pubsub Next Redis reconnect attempt in 3s INFO 2021-07-23T03:37:09.644Z context=rpc RPC controller initialized: localhost:50051 (concurrency: 28, enable_tls: false, proto _versions: v1) INFO 2021-07-23T03:37:12.645Z context=pubsub Reconnecting to Redis... WARN 2021-07-23T03:37:12.646Z context=pubsub Redis connection failed: dial tcp 127.0.0.1:6379: connect: connection refused
=== root@goorm:/workspace/studying_app# anycable-go INFO 2021-07-23T03:37:36.737Z context=main Starting AnyCable 1.1.2-bbf4cae (pid: 779, open file limit: 1024) INFO 2021-07-23T03:37:36.747Z context=main Handle WebSocket connections at http://localhost:8080/cable INFO 2021-07-23T03:37:36.756Z context=main Handle health connections at http://localhost:8080/health WARN 2021-07-23T03:37:36.748Z context=pubsub Redis connection failed: dial tcp 127.0.0.1:6379: connect: connection refused INFO 2021-07-23T03:37:36.760Z context=pubsub Next Redis reconnect attempt in 3s INFO 2021-07-23T03:37:36.753Z context=rpc RPC controller initialized: localhost:50051 (concurrency: 28, enable_tls: false, proto _versions: v1) INFO 2021-07-23T03:37:39.761Z context=pubsub Reconnecting to Redis... WARN 2021-07-23T03:37:39.762Z context=pubsub Redis connection failed: dial tcp 127.0.0.1:6379: connect: connection refused
and, i'm using IDE system. so when i test my web i'm using the url "https://studying-app-iloagg.run.goorm.io/" not localhost:3000.
the url means 8080 port.
veryveryvery thanks again...!!
Cool!
Now you need to resolve this (install Redis):
Redis connection failed: dial tcp 127.0.0.1:6379: connect: connection refused
Thanks for your replying!!
i installed by "gem install redis" (is it right?)
and... rails s -b 0.0.0.0 -p 3000 -p 8080
and anycable-go
then...
======< in my terminal >======= INFO 2021-07-23T14:11:22.164Z context=main Starting AnyCable 1.1.2-bbf4cae (pid: 3432, open file limit: 1024) INFO 2021-07-23T14:11:22.164Z context=main Handle WebSocket connections at http://localhost:8080/cable INFO 2021-07-23T14:11:22.164Z context=main Handle health connections at http://localhost:8080/health WARN 2021-07-23T14:11:22.165Z context=pubsub Redis connection failed: dial tcp 127.0.0.1:6379: connect: connection refused INFO 2021-07-23T14:11:22.165Z context=pubsub Next Redis reconnect attempt in 3s INFO 2021-07-23T14:11:22.165Z context=rpc RPC controller initialized: localhost:50051 (concurrency: 28, enable_tls: false, proto _versions: v1) WebSocket server at http://localhost:8080 stopped: listen tcp 127.0.0.1:8080: bind: address already in use
======< in my server side >======= Started GET "/cable" for 172.17.0.1 at 2021-07-23 14:21:11 +0000 Cannot render console from 172.17.0.1! Allowed networks: 127.0.0.0/127.255.255.255, ::1 You're trying to connect to Action Cable server while using AnyCable. See https://docs.anycable.io/troubleshooting?id=server-raise s-an-argumenterror-exception-when-client-tries-to-connect Finished "/cable/" [AnyCable] for 172.17.0.1 at 2021-07-23 14:21:11 +0000 (Closed)
======< client chrome console >======= WebSocket connection to 'wss://studying-app-iloagg.run.goorm.io/cable' failed:
thanks for your very kindful reply despite im so beginner and can't doing well.
Thanks
i installed by "gem install redis" (is it right?)
Not really; it's a client library, you need a server itself.
Like, apt install redis
or smth like that.
i installed by "gem install redis" (is it right?)
Not really; it's a client library, you need a server itself.
Like,
apt install redis
or smth like that.
@palkan Thanks. I did it. But there is nothing changed.....
in my client chrome console
WebSocket connection to 'wss://studying-app-iloag.run.goorm.io/cable' failed:
So i changed may time consumer.js
import { createConsumer } from "@rails/actioncable" export default createConsumer('wss://studying-app-iloag.run.goorm.io/cable')
where the url in it.
changed like ws://studying-app-iloag.run.goorm.io/cable wss://studying-app-iloag.run.goorm.io:8080/cable
ws://studying-app-iloagg.run.goorm.io/cable (where 8080port connected) ws://studying-app-iloagg.run.goorm.io:8080/cable
so... i wanna know where the problem is...
port forwarding studying-app-iloag.run.goorm.io port 3000 studying-app-iloagg.run.goorm.io port 8080 studying-app-iloaggg.run.goorm.io port 6379
First, I did
rails server -b 0.0.0.0 -p 3000
Second
anycable-go
Third turn on the url
....
so, where is the problem? or you need more information to help me out?
i can't figure out cause im just so beginner... sorry and very thankful about your consistant reply.
Thanks.
or you need more information to help me out?
Yeah. Do you have access to logs? Can you run anycable-go
with -debug
flag and capture its output? The question is whether there is a forwarding problem (sockets cannot reach the WS server) or it's something related to services communication (then, we should see something in logs).
@palkan Thanks!!!!!!!
DEBUG 2021-07-27T11:50:28.584Z context=main 🔧 🔧 🔧 Debug mode is on 🔧 🔧 🔧 INFO 2021-07-27T11:50:28.585Z context=main Starting AnyCable 1.1.2-bbf4cae (pid: 606, open file limit: 1024) DEBUG 2021-07-27T11:50:28.589Z context=disconnector Calls rate: 10ms WARN 2021-07-27T11:50:28.600Z context=pubsub Redis connection failed: dial tcp 127.0.0.1:6379: connect: connection refused INFO 2021-07-27T11:50:28.612Z context=pubsub Next Redis reconnect attempt in 3s INFO 2021-07-27T11:50:28.612Z context=main Handle WebSocket connections at http://localhost:8080/cable INFO 2021-07-27T11:50:28.617Z context=main Handle health connections at http://localhost:8080/health DEBUG 2021-07-27T11:50:28.626Z context=main Go pools initialized (broadcast: 16) INFO 2021-07-27T11:50:28.618Z context=rpc RPC controller initialized: localhost:50051 (concurrency: 28, enable_tls: false, proto _versions: v1) DEBUG 2021-07-27T11:50:28.628Z context=http Starting WebSocket server at http://localhost:8080 DEBUG 2021-07-27T11:50:28.628Z context=metrics No metrics writers. Disable metrics rotation INFO 2021-07-27T11:50:31.615Z context=pubsub Reconnecting to Redis... WARN 2021-07-27T11:50:31.615Z context=pubsub Redis connection failed: dial tcp 127.0.0.1:6379: connect: connection refused INFO 2021-07-27T11:50:31.616Z context=pubsub Next Redis reconnect attempt in 25s
.....
after some Redis reconnect attempts....
!!! Subscriber failed !!! Redis reconnect attempts exceeded
On this situation, if i send some message to another user(i made), happened nothing.
Just added user-id and message content at the end of url like
"http://studying-app-iloag.run.goorm.io/?conversation_id=1&user_id=1&body=hihihi"
So... is there any more needed information that i can give you?
@kerbong, looks like Redis server still isn't running. You have to launch it, ensure it is running and listening on localhost port 6379 (these are defaults) before launching either anycable or rails. Redis is essential as all communication between anycable and rails is going through it.
To start Redis on Linux you should execute command like this:
sudo systemctl start redis
and check if it is running like this (it should be on active (running)
state):
$ sudo systemctl status redis.service
● redis.service - Advanced key-value store
Loaded: loaded (/usr/lib/systemd/system/redis.service; disabled; vendor preset: disabled)
Active: active (running) since Tue 2021-07-27 15:16:21 MSK; 4min 32s ago
Main PID: 8832 (redis-server)
Status: "Ready to accept connections"
Tasks: 5 (limit: 38350)
Memory: 4.0M
CPU: 916ms
CGroup: /system.slice/redis.service
└─8832 /usr/bin/redis-server 127.0.0.1:6379
And you can check connectivity with redis-cli
tool (should be installed along Redis server, but not sure):
$ redis-cli -h 127.0.0.1 -p 6379
127.0.0.1:6379>
But if you're getting following message, then it is not ready to be used yet:
$ redis-cli -h 127.0.0.1 -p 6379
Could not connect to Redis at 127.0.0.1:6379: Connection refused
not connected>
If you run Redis and application inside Docker containers then you need to use Docker hostnames in anycable configuration.
@Envek Thanks!!! but i can't "sudo systemctl start redis". If i did it terminal, message "System has not been booted with systemd as init system (PID 1). Can't operate." appeared.
and, on terminal
$ redis-server
there are lines on terminal
13151:M 27 Jul 17:09:37.100 # WARNING: The TCP backlog setting of 511 cannot be enforced because /proc/sys/net/core/somaxconn is s et to the lower value of 128. 13151:M 27 Jul 17:09:37.100 # Server initialized 13151:M 27 Jul 17:09:37.100 # WARNING overcommit_memory is set to 0! Background save may fail under low memory condition. To fix t his issue add 'vm.overcommit_memory = 1' to /etc/sysctl.conf and then reboot or run the command 'sysctl vm.overcommit_memory=1' fo r this to take effect. 13151:M 27 Jul 17:09:37.100 # WARNING you have Transparent Huge Pages (THP) support enabled in your kernel. This will create latency and memory usage issues with Redis. To fix this issue run the command 'echo never > /sys/kernel/mm/transparent_hugepage/enabled ' as root, and add it to your /etc/rc.local in order to retain the setting after a reboot. Redis must be restarted after THP is di sabled. 13151:M 27 Jul 17:09:37.100 DB loaded from disk: 0.000 seconds 13151:M 27 Jul 17:09:37.100 Ready to accept connections
....
is it right??
and I saw some stackoverflow advise like, "you should use 6379/1 at redis server if you want to use both your main Rails and Redis."
So.. in my anycable.yml
` default: &default
rpc_host: "127.0.0.1:50051"
log_grpc: false
broadcast_adapter: redis
redis_channel: "anycable"
development: <<: *default redis_url: redis://localhost:6379/1
test: <<: *default
production: <<: *default redis_url: redis://studying-app-iloag.run.goorm.io:6379/1 access_logs_disabled: false `
And I didn't use Docker... (i don't know what it is...haha... i'm using IDE cloud system, not cloud9 but goorm IDE..)
13151:M 27 Jul 17:09:37.100 * Ready to accept connections
That's right. Now, while it is running, you can use any cables you want.
P.S> Please use Markdown formatting in your messages. They are painful to read and understand. Help us to help you!
Thanks your advice again..!!
========
when i write this on terminal
apt install redis => already installed messages appears
and, also i can get
13151:M 27 Jul 17:09:37.100 * Ready to accept connections
but I got some trouble sending message to other testing user by anycables.
first.
i ran the
rails server
second.
and at the server terminal
redis-server
(Ready to accept connections)
third. I got some trouble sending message to other testing user. there was nothing changed.. x _ x
first.
rails-server
second.
anycable-go
third. I got some trouble sending message to other testing user. there was nothing changed.. x _ x
and, client console
WebSocket connection to 'wss://studying-app-iloag.run.goorm.io/cable' failed:
repeated,
server-side console
You're trying to connect to Action Cable server while using AnyCable. See https://docs.anycable.io/troubleshooting?id=server-raise s-an-argumenterror-exception-when-client-tries-to-connect Finished "/cable/" [AnyCable] for 172.17.0.1 at 2021-07-29 18:36:17 +0000 (Closed) Started GET "/cable" for 172.17.0.1 at 2021-07-29 18:36:29 +0000 Cannot render console from 172.17.0.1! Allowed networks: 127.0.0.0/127.255.255.255, ::1
repeated...
1.
is there a problem ??
You're trying to connect to Action Cable server while using AnyCable. See https://docs.anycable.io/troubleshooting?id=server-raise s-an-argumenterror-exception-when-client-tries-to-connect
(i can't understand that url's content.. and i think that is not a right way for me.)
1-1. but if there is, what's the different between anycable and anycable-go??
2. I guess that the problem is cause of port forwarding.
when i Changed
app/javascript/channel/consumer.js
code,
2-1.
export default createConsumer('wss://studying-app-iloaggg.run.goorm.io/cable') << port 6379
action_cable.js:241 WebSocket connection to 'wss://studying-app-iloaggg.run.goorm.io/cable' failed: Error during WebSocket handshake: Invalid status line
2-2.
export default createConsumer('wss://studying-app-iloagg.run.goorm.io/cable') << port 8080
WebSocket connection to 'wss://studying-app-iloagg.run.goorm.io/cable' failed: Error during WebSocket handshake: Unexpected response code: 404
2-3.
export default createConsumer('wss://studying-app-iloag.run.goorm.io/cable') << port 3000
action_cable.js:241 WebSocket connection to 'wss://studying-app-iloag.run.goorm.io/cable' failed: Error during WebSocket handshake: Unexpected response code: 200
so,, thanks again your help!!!
@palkan @Envek Thanks!!!!! i got some advances on my anycable base realtime test app.!!!!!
<head> ... <meta name="action-cable-url" content="ws://studying- ......... .io:8080/cable">
anycable-go
into terminal` INFO 2021-08-01T19:19:04.341Z context=main Starting AnyCable 1.1.2-bbf4cae (pid: 19330, open file limit: 1024) INFO 2021-08-01T19:19:04.341Z context=main Handle WebSocket connections at http://localhost:8080/cable INFO 2021-08-01T19:19:04.341Z context=main Handle health connections at http://localhost:8080/health INFO 2021-08-01T19:19:04.342Z context=pubsub Subscribed to Redis channel: anycable
INFO 2021-08-01T19:19:04.343Z context=rpc RPC controller initialized: localhost:50051 (concurrency: 28, enable_tls: false, proto_versions: v1)`
Hey!!
to another test user, in my server consoleProcessing by MessagesController#create as JS Parameters: {"utf8"=>"✓", "message"=>{"user_id"=>"1", "conversation_id"=>"3", "body"=>"Hey!!"}, "authenticity_token"=>"Gphck0oABM79NGZDKWdB5Jlwins52fhIxnjKK/jq wUunP2u8LfkmUxfLPwUAM29MugIMk5Q5xhOCtSqWK6lAGg==", "commit"=>"보내기", "conversation_id"=>"3"} User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = ? ORDER BY "users"."id" ASC LIMIT ? [["id", 1], ["LIMIT", 1]] Conversation Load (0.1ms) SELECT "conversations".* FROM "conversations" WHERE "conversations"."id" = ? LIMIT ? [["id", 3], ["LIMIT", 1]] ↳ app/controllers/messages_controller.rb:3:in
create'
User Load (0.2ms) SELECT "users". FROM "users" WHERE "users"."id" = ? [["id", 4]]
↳ app/controllers/messages_controller.rb:3:in create' (0.1ms) begin transaction ↳ app/controllers/messages_controller.rb:4:in
create'
User Load (0.2ms) SELECT "users". FROM "users" WHERE "users"."id" = ? LIMIT ? [["id", 1], ["LIMIT", 1]]
↳ app/controllers/messages_controller.rb:4:in create' Message Create (1.1ms) INSERT INTO "messages" ("body", "user_id", "conversation_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["body", "Hey!!"], [ user_id", 1], ["conversation_id", 3], ["created_at", "2021-08-01 19:50:01.582102"], ["updated_at", "2021-08-01 19:50:01.582102"]] ↳ app/controllers/messages_controller.rb:4:in
create'
(15.8ms) commit transaction
↳ app/controllers/messages_controller.rb:4:in create' [ActiveJob] Enqueued MessageBroadcastJob (Job ID: fb2493e2-4014-470a-b016-d65824cb54bc) to Async(default) with arguments: #<GlobalID:0x00005594ad50ba80 @uri=#<UR I::GID gid://goorm-rails-app/Message/36>> Message Load (0.2ms) SELECT "messages".* FROM "messages" WHERE "messages"."id" = ? LIMIT ? [["id", 36], ["LIMIT", 1]] [ActiveJob] [MessageBroadcastJob] [fb2493e2-4014-470a-b016-d65824cb54bc] Performing MessageBroadcastJob (Job ID: fb2493e2-4014-470a-b016-d65824cb54bc) from Async (default) enqueued at 2021-08-01T19:50:01Z with arguments: #<GlobalID:0x00005594ad5ba5d0 @uri=#<URI::GID gid://goorm-rails-app/Message/36>> [ActiveJob] [MessageBroadcastJob] [fb2493e2-4014-470a-b016-d65824cb54bc] User Load (0.1ms) SELECT "users".* FROM "users" WHERE "users"."id" = ? LIMIT ? [["id , 1], ["LIMIT", 1]] [ActiveJob] [MessageBroadcastJob] [fb2493e2-4014-470a-b016-d65824cb54bc] ↳ app/jobs/message_broadcast_job.rb:5:in
perform'
Rendered messages/_message.html.erb (Duration: 0.1ms | Allocations: 11)
[ActiveJob] [MessageBroadcastJob] [fb2493e2-4014-470a-b016-d65824cb54bc] Conversation Load (0.2ms) SELECT "conversations".* FROM "conversations" WHERE "conver
sations"."id" = ? LIMIT ? [["id", 3], ["LIMIT", 1]]
[ActionCable] Broadcasting to conversationchannel: {:message=>"
"} Completed 200 OK in 72ms (Views: 2.1ms | ActiveRecord: 17.6ms | Allocations: 12739)
[ActiveJob] [MessageBroadcastJob] [fb2493e2-4014-470a-b016-d65824cb54bc] ↳ app/jobs/message_broadcast_job.rb:6:in perform' [ActiveJob] [MessageBroadcastJob] [fb2493e2-4014-470a-b016-d65824cb54bc] User Load (0.1ms) SELECT "users".* FROM "users" WHERE "users"."id" = ? LIMIT ? [["id , 4], ["LIMIT", 1]] [ActiveJob] [MessageBroadcastJob] [fb2493e2-4014-470a-b016-d65824cb54bc] ↳ app/models/conversation.rb:22:in
opposed_user'
[ActiveJob] [MessageBroadcastJob] [fb2493e2-4014-470a-b016-d65824cb54bc] Rendered messages/_message.html.erb (Duration: 0.1ms | Allocations: 11)
[ActiveJob] [MessageBroadcastJob] [fb2493e2-4014-470a-b016-d65824cb54bc] [ActionCable] Broadcasting to conversations-1: {:message=>"
Two kinds of errors appeared from client console.
If i change the consumer.js
export default createConsumer('ws://studying-app-iloagg.run.goorm.io:8080/cable')
==> WebSocket connection to 'ws://studying-app-iloagg.run.goorm.io:8080/cable' failed: WebSocket is closed before the connection is established.
export default createConsumer('ws://localhost:8080/cable')
==> WebSocket connection to 'ws://localhost:8080/cable' failed
So that I can't see the send message Hey!!
realtime...
Thanks again and hope your patience persistent...!!!!! And Thanks again for reading my messy questions. ^^
export default createConsumer('ws://studying-app-iloagg.run.goorm.io:8080/cable')
==> WebSocket connection to 'ws://studying-app-iloagg.run.goorm.io:8080/cable' failed: WebSocket is closed before the connection is established.
That's probably because your WebSocket connection isn't properly proxied to anycable-go process (or is forwarded to your web application process instead, which is correct for ActionCable, but wrong for AnyCable).
I don't really understand how this Goorm IDE is working and how it launches your application, but, in general, when there is a load balancer in front of your application, it MUST support WebSocket protocol and, sometimes, also must be additionally configured (e.g. see example for Nginx)
@Envek Thanks. After your reply I've tried another real time chat testing web. And, I can send real-time messaging with action-cable.
Then, i tried anycable install.(following your steps.)
So, now i vaguely understand about anycable, but except which is properly proxied to anycable-go. When I send message, there(in Chrome console) is no-error about anything.
But i got error
action_cable.js:241 WebSocket connection to 'ws://localhost:8080/cable' failed:
details
open @ action_cable.js:241 reopen @ action_cable.js:276 reconnectIfStale @ action_cable.js:154 (anonymous) @ action_cable.js:130
====== and i dont understand what you mentioned.
That's probably because your WebSocket connection isn't properly proxied to anycable-go process (or is forwarded to your web application process instead, which is correct for ActionCable, but wrong for AnyCable).
What's the correct proxy to anycable-go??
Hi, im a beginner RoR student. and it was so confusing cause i don't know where(or what) ther problem is... so if you can give some advice, it will really helpful. Thanks for your kindness.
Tell us about your environment
Using goorm ide (online cloud development system) https://ide.goorm.io/
Ruby version: 2.6.5
Rails version: 6.0.4
anycable
gem version: 1.1.1anycable-rails
gem version: 1.1.2grpc
gem version: 1.38.0What did you do?
==== Installed ... (in my upper gemfile)
gem 'bootstrap', '~> 4.0' gem 'autoprefixer-rails' gem "anycable-rails", "~> 1.1" gem 'devise'
when using Redis broadcast adapter
gem "redis", ">= 4.0" gem 'grpc'
==== and the base is same ... https://www.nopio.com/blog/rails-chat-application-actioncable/ or https://github.com/nopio/facebook-chat-part2
=== and after that reference( https://medium.com/geekculture/actioncable-to-anycable-c9d9d54665f0 )
=== config/cable.yml
development: adapter: anycable
production: adapter: anycable
=== config/environments/production.rb
Rails.application.configure do config.after_initialize do config.action_cable.url = "wss://studying-app-iloag.run.goorm.io:50051/cable" config.action_cable.allowed_request_origins = ['https://studying-app-iloag.run.goorm.io'] end .....
=== config/environments/development.rb
Rails.application.configure do config.after_initialize do config.action_cable.url = "ws://localhost:50051/cable" config.action_cable.allowed_request_origins = ['http://localhost:3000'] end ..
=== config/anycable.yml
default: &default access_logs_disabled: false rpc_host: "127.0.0.1:50051" log_grpc: false broadcast_adapter: redis redis_channel: "anycable"
development: rpc_host: "localhost:50051" # Host and port of the RPC host redis_url: "redis://development_redis_url:6379"
production: rpc_host: "localhost:50051" # Host and port of the RPC host redis_url: "redis://production_redis_url:6379"
test: <<: *default
=== on terminal
sudo apt-get install golang-go sudo apt update sudo apt install golang-go go get -u -f github.com/anycable/anycable-go/cmd/anycable-go
and
i met the truble. so i googling...
found this. https://github.com/anycable/anycable-rails/issues/115
and,,,
layouts/application.html.erb
fount this. https://github.com/anycable/anycable-rails/issues/127
and...
config/environment/development.rb
config/application.rb.
routes.rb
.... mount ActionCable.server => '/cable' << added.. end
but, nothing changed...haha..
What did you expect to happen?
I expected that I can make realtime messaging web app
What actually happened?
1. i don't sure that I installed anycable-go correctly. ... when i enter "anycable-go"at terminal, message "can't find command" printed...
2. when i click send button, window page reloaded and added http address part like"&user_id=1&body=wdfsdf" and on my Chrome console, "WebSocket connection to 'ws://localhost:50051/cable' failed: " printed intevally...