@@ -1908,19 +1908,18 @@ module Puma
1908
1908
# ...
1909
1909
thread= server.run# Let's step into this line later.
1910
1910
1911
- # This line will suspend the mainprocess execution.
1912
- # And the `thread`'s block (which is method `handle_servers`) will be executed in mainprocess .
1911
+ # This line will suspend the mainthread execution.
1912
+ # And the `thread`'s block (which is method `handle_servers`) will be executed in mainthread .
1913
1913
# See `Thread#join` for more information.
1914
1914
# I will show you a simple example for using `thread.join`.
1915
1915
# Please search `test_thread_join.rb` in this document.
1916
1916
thread.join
1917
1917
1918
- # The below line will never be executed because `thread` is always running
1919
- # and `thread` has joined to main process.
1918
+ # The below line will never be executed because `thread` is always running and `thread` has joined.
1920
1919
# When `$ kill -s SIGTERM puma_process_id`, the below line will still not be executed
1921
1920
# because the block of `Signal.trap "SIGTERM"` in `Puma::Launcher#setup_signals` will be executed.
1922
1921
# If you remove the line `thread.join`, the below line will be executed,
1923
- # but the mainprocess will exit after all code executed and all the threads not joined will be killed.
1922
+ # but the mainthread will exit after all code executed and all the threads not joined will be killed.
1924
1923
puts " anything which will never be executed..."
1925
1924
end
1926
1925
end
@@ -1992,8 +1991,6 @@ module Puma
1992
1991
# ...
1993
1992
1994
1993
if background# background: true (for this example)
1995
- #
1996
- puts " #{ Thread .current.object_id} "
1997
1994
1998
1995
# It's important part.
1999
1996
# Remember puma created a thread here!