You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
check the number of threads: ps -o thcount <RPC-PID>
THCNT
45
This number is the same locally, on staging and on prod
What did you expect to happen?
Use less threads or let me control it, like with puma's RAILS_MAX_THREADS or sidekiq's concurrency
What actually happened?
I'm load testing a chat app, it works fine for small number of users
but when i increase number of concurrent users, latency increases, up to 3-4s (depending on number of concurrent users)
I've a trace of my chat code
As you see, it takes ~500ms to start executing method's code (on ruby channel class).
I'm not sure what blank sections in trace signify but I'm guessing it could be waiting to acquire GVL to start executing. But i cannot verify it, since GVL instrumentation API was added in Ruby 3.2.0 and I'm on Ruby 2.7.
I'm trying to use less threads to check if latency decreases (waits are shorter),
how can i control bundle exec anycable's thread count?
The text was updated successfully, but these errors were encountered:
Tell us about your environment
Ruby version:
2.7
Rails version:
5.2
anycable
gem version:~> 0.6.0
anycable-rails
gem version:0.6.5
grpc
gem version:~> 1.17
What did you do?
I ran rpc process
bundle exec anycable
check the number of threads:
ps -o thcount <RPC-PID>
This number is the same locally, on staging and on prod
What did you expect to happen?
Use less threads or let me control it, like with puma's
RAILS_MAX_THREADS
or sidekiq's concurrencyWhat actually happened?
I'm load testing a chat app, it works fine for small number of users
but when i increase number of concurrent users, latency increases, up to 3-4s (depending on number of concurrent users)
I've a trace of my chat code
As you see, it takes ~500ms to start executing method's code (on ruby channel class).
I'm not sure what blank sections in trace signify but I'm guessing it could be waiting to acquire GVL to start executing. But i cannot verify it, since GVL instrumentation API was added in Ruby
3.2.0
and I'm on Ruby2.7
.I'm trying to use less threads to check if latency decreases (waits are shorter),
how can i control
bundle exec anycable
's thread count?The text was updated successfully, but these errors were encountered: