diff --git a/lib/puma/server.rb b/lib/puma/server.rb index 41fb4661..553d32ad 100644 --- a/lib/puma/server.rb +++ b/lib/puma/server.rb @@ -69,6 +69,7 @@ class Server # calling code to not require events.rb. # def initialize(app, events = nil, options = {}) + @closed_conections = 0 @app = app @events = events || Events.new @@ -393,6 +394,7 @@ def handle_servers end graceful_shutdown if @status == :stop || @status == :restart +STDOUT.syswrite "\n********* @closed_conections #{@closed_conections} reactor #{@reactor&.selector_size_max} tp #{pool&.backlog_max}\n" rescue Exception => e @log_writer.unknown_error e, nil, "Exception handling servers" ensure @@ -467,6 +469,7 @@ def process_client(client) case handle_request(client, requests + 1) when false # ok, we're done + @closed_conections += 1 when :async close_socket = false when true