Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add new metrics busy_threads from Puma #333

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

benoittgt
Copy link

New Puma version has a nice addition of metric on busy threads.

busy_threads: running - how many threads are waiting to receive work + how many requests are waiting for a thread to pick them up. this is a "wholistic" stat reflecting the overall current state of work to be done and the capacity to do it.
source

Expose a prometheus metric new thread stats from Puma

- puma/puma#3517
PrometheusExporterMiddlewareTest#test_redis_5_call_pipelined_patching:
ArgumentError: wrong number of arguments (given 2, expected 3)
    test/test_helper.rb:12:in `call_pipelined'
    /Users/benoit.tigeot/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/redis-client-0.19.1/lib/redis_client.rb:412:in `block (2 levels) in pipelined'
    /Users/benoit.tigeot/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/redis-client-0.19.1/lib/redis_client/middlewares.rb:16:in `call'
    test/test_helper.rb:60:in `call_pipelined'
    lib/prometheus_exporter/instrumentation/method_profiler.rb:67:in `call_pipelined'
    /Users/benoit.tigeot/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/redis-client-0.19.1/lib/redis_client.rb:411:in `block in pipelined'
    /Users/benoit.tigeot/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/redis-client-0.19.1/lib/redis_client.rb:677:in `ensure_connected'
    /Users/benoit.tigeot/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/redis-client-0.19.1/lib/redis_client.rb:409:in `pipelined'
    /Users/benoit.tigeot/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/redis-client-0.19.1/lib/redis_client/pooled.rb:57:in `block in pipelined'
    /Users/benoit.tigeot/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/redis-client-0.19.1/lib/redis_client/pooled.rb:30:in `block in with'
    /Users/benoit.tigeot/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/connection_pool-2.4.1/lib/connection_pool.rb:110:in `block (2 levels) in with'
    /Users/benoit.tigeot/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/connection_pool-2.4.1/lib/connection_pool.rb:109:in `handle_interrupt'
    /Users/benoit.tigeot/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/connection_pool-2.4.1/lib/connection_pool.rb:109:in `block in with'
    /Users/benoit.tigeot/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/connection_pool-2.4.1/lib/connection_pool.rb:106:in `handle_interrupt'
    /Users/benoit.tigeot/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/connection_pool-2.4.1/lib/connection_pool.rb:106:in `with'
    /Users/benoit.tigeot/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/redis-client-0.19.1/lib/redis_client/pooled.rb:26:in `with'
    /Users/benoit.tigeot/.rbenv/versions/3.3.4/lib/ruby/gems/3.3.0/gems/redis-client-0.19.1/lib/redis_client/pooled.rb:57:in `pipelined'
    test/middleware_test.rb:118:in `test_redis_5_call_pipelined_patching'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

1 participant