mirror of
https://github.com/puma/puma.git
synced 2022-11-09 13:48:40 -05:00
![]() * Add pumactl command to print thread backtraces Completes 1 of 2 items from #1964 This commit adds an endpoint to the status app to print thread backtraces, and control cli command to call that endpoint. I tried this locally by starting a server with: ```sh bundle exec bin/puma test/rackup/hello.ru \ --control-url="unix://test.sock" \ --control-token="token" ``` and then printing the backtraces with: ```sh bundle exec bin/pumactl thread-backtraces \ --control-url="unix://test.sock" \ --control-token="token" ``` * Log threads as JSON in control app With this commit the status app sends the thread backtraces as an array of objects with `name` and `backtrace` keys, rather than as a string matching the SIGINFO output. While working on this I noticed that we logged the thread TID twice. This commit simplifies that so we only log the thread TID once, with both the label (I don't know when the label would get set) and name if they are available. |
||
---|---|---|
.. | ||
config | ||
helpers | ||
rackup | ||
shell | ||
helper.rb | ||
test_app_status.rb | ||
test_binder.rb | ||
test_cli.rb | ||
test_config.rb | ||
test_events.rb | ||
test_http10.rb | ||
test_http11.rb | ||
test_integration_cluster.rb | ||
test_integration_pumactl.rb | ||
test_integration_single.rb | ||
test_iobuffer.rb | ||
test_launcher.rb | ||
test_minissl.rb | ||
test_null_io.rb | ||
test_persistent.rb | ||
test_plugin.rb | ||
test_puma_server.rb | ||
test_puma_server_ssl.rb | ||
test_pumactl.rb | ||
test_rack_handler.rb | ||
test_rack_server.rb | ||
test_tcp_logger.rb | ||
test_tcp_rack.rb | ||
test_thread_pool.rb | ||
test_unix_socket.rb | ||
test_web_server.rb |