Comments (3)
Looks like RPC call failed. Can you, please, provide me with RPC server logs? (To turn on verbose logging start it with ANYCABLE_DEBUG=1 ./bin/anycable
).
Also, which versions of anycable-go
and anycable
gem do you use?
from anycable-go.
I'm using the latest versions of everything at the time of this writing.
Looks like the problem isn't with anycable-go (should probably move this anycable-rails then)
Looking at the debug output, there's a problem with me logging with the user email as a tag:
$ ANYCABLE_DEBUG=1 be ruby bin/anycable 130 ↵
I, [2017-01-31T22:10:39.510844 #43649] INFO -- : handling /anycable.RPC/Connect with #<Method: Anycable::RPCHandler#connect>
I, [2017-01-31T22:10:39.510948 #43649] INFO -- : handling /anycable.RPC/Command with #<Method: Anycable::RPCHandler#command>
I, [2017-01-31T22:10:39.510980 #43649] INFO -- : handling /anycable.RPC/Disconnect with #<Method: Anycable::RPCHandler#disconnect>
I, [2017-01-31T22:10:39.511046 #43649] INFO -- : RPC server is listening on localhost:50051
I, [2017-01-31T22:10:42.291773 #43649] INFO -- : waiting: 0, max: 20
I, [2017-01-31T22:10:42.291889 #43649] INFO -- : deadline is 1970-01-01 01:59:59 +0200; (now=2017-01-31 22:10:42 +0200)
I, [2017-01-31T22:10:42.292013 #43649] INFO -- : schedule another job
D, [2017-01-31T22:10:42.293688 #43649] DEBUG -- : RPC Connect: #<Anycable::ConnectionRequest:0x007f96fd4e1ba0>
W, [2017-01-31T22:10:42.344544 #43649] WARN -- : failed handler: #<GRPC::ActiveCall:0x007f96fd4e1f60>; sending status:UNKNOWN
W, [2017-01-31T22:10:42.344597 #43649] WARN -- : undefined method `add_tags' for #<ActiveSupport::Logger:0x007f96feb5a760> (NoMethodError)
/Users/daniel/Projects/fuza17/app/channels/application_cable/connection.rb:7:in `connect'
/Users/daniel/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/anycable-rails-0.4.3/lib/anycable/rails/actioncable/connection.rb:42:in `handle_open'
/Users/daniel/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/anycable-0.4.2/lib/anycable/rpc_handler.rb:19:in `connect'
/Users/daniel/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/grpc-1.0.1-universal-darwin/src/ruby/lib/grpc/generic/rpc_desc.rb:71:in `call'
/Users/daniel/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/grpc-1.0.1-universal-darwin/src/ruby/lib/grpc/generic/rpc_desc.rb:71:in `run_server_method'
/Users/daniel/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/grpc-1.0.1-universal-darwin/src/ruby/lib/grpc/generic/rpc_server.rb:368:in `block in loop_handle_server_calls'
/Users/daniel/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/grpc-1.0.1-universal-darwin/src/ruby/lib/grpc/generic/rpc_server.rb:132:in `block in loop_execute_jobs'
/Users/daniel/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/grpc-1.0.1-universal-darwin/src/ruby/lib/grpc/generic/rpc_server.rb:129:in `loop'
/Users/daniel/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/grpc-1.0.1-universal-darwin/src/ruby/lib/grpc/generic/rpc_server.rb:129:in `loop_execute_jobs'
/Users/daniel/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/grpc-1.0.1-universal-darwin/src/ruby/lib/grpc/generic/rpc_server.rb:82:in `block (2 levels) in start'
/Users/daniel/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/grpc-1.0.1-universal-darwin/src/ruby/lib/grpc/generic/rpc_server.rb:81:in `catch'
/Users/daniel/.rbenv/versions/2.3.3/lib/ruby/gems/2.3.0/gems/grpc-1.0.1-universal-darwin/src/ruby/lib/grpc/generic/rpc_server.rb:81:in `block in start'
This comes from my application connection:
module ApplicationCable
class Connection < ActionCable::Connection::Base
identified_by :current_user
def connect
self.current_user = find_verified_user
logger.add_tags 'ActionCable', current_user.email
end
protected
def find_verified_user # this checks whether a user is authenticated with devise
if verified_user = User.find_by(id: cookies.signed["user.id"])
verified_user
else
reject_unauthorized_connection
end
end
end
end
from anycable-go.
I've solved my problem for the time being. Commenting out that line solves the error.
I had another issue, that my messages weren't being received by my clients (except for pings and the usual actioncable messages). But I resolved it by putting my initial broadcasts in a thread that runs a second after subscribing to a channel.
from anycable-go.
Related Issues (20)
- Client cannot reconnect after going to sleep HOT 10
- GRPC max message size HOT 4
- JWT auth enhancements HOT 1
- TurboDrive/TurboStream Subscribe/Unsubscribe Race Condition HOT 16
- readme shows invalid "go get" command HOT 1
- became root HOT 3
- Cookies filter HOT 3
- Metrics anycable_go_clients_num and anycable_go_clients_uniq_num count are not update correctly HOT 5
- Hide `Disconnect error: grpc connection is not ready` message HOT 1
- Unable to run it's docker image on M1 Mac
- Latest docker image missing GLIBC_2.29 HOT 6
- Feature Request: TLS on rpc service HOT 1
- Panic during history retrieval HOT 4
- Panic during history retrieval with 1.4.2 fix HOT 3
- Anycable-go ignores Redis database number HOT 1
- Failed to install by source HOT 2
- Posthog HOT 1
- Support redis socket url? HOT 11
- Intermittent GoAway Error with ENHANCE_YOUR_CALM Code in AnyCable-Go 1.4.8 Despite Functional Setup HOT 1
- WRN Using a non-distributed broadcaster without a pub/sub enabled HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from anycable-go.