about summary refs log tree commit homepage
path: root/lib/rainbows/thread_pool.rb
diff options
context:
space:
mode:
authorEric Wong <normalperson@yhbt.net>2010-07-10 08:04:48 +0000
committerEric Wong <normalperson@yhbt.net>2010-07-10 08:04:48 +0000
commitd3b97d1114e2d23a9231fe889cd5bf6927d451ba (patch)
tree6c4d7a033dad1edc91b72a9e7fa36203c60c8116 /lib/rainbows/thread_pool.rb
parent9838b614621bbbff27a91166406d833be85adbbd (diff)
downloadrainbows-d3b97d1114e2d23a9231fe889cd5bf6927d451ba.tar.gz
Since we suck at building websites, we just rely on RDoc as a
website builder.  And since Rainbows! is an application server
(and not a programming library), our internal API should be of
little interest to end users.

Anybody interested in Rainbows! (or any other project) internals
should be reading the source.
Diffstat (limited to 'lib/rainbows/thread_pool.rb')
-rw-r--r--lib/rainbows/thread_pool.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/rainbows/thread_pool.rb b/lib/rainbows/thread_pool.rb
index f609483..28a943e 100644
--- a/lib/rainbows/thread_pool.rb
+++ b/lib/rainbows/thread_pool.rb
@@ -25,7 +25,7 @@ module Rainbows
 
     include Base
 
-    def worker_loop(worker)
+    def worker_loop(worker) # :nodoc:
       init_worker_process(worker)
       pool = (1..worker_connections).map do
         Thread.new { LISTENERS.size == 1 ? sync_worker : async_worker }
@@ -41,7 +41,7 @@ module Rainbows
       join_threads(pool)
     end
 
-    def sync_worker
+    def sync_worker # :nodoc:
       s = LISTENERS[0]
       begin
         c = Rainbows.sync_accept(s) and process_client(c)
@@ -50,7 +50,7 @@ module Rainbows
       end while G.alive
     end
 
-    def async_worker
+    def async_worker # :nodoc:
       begin
         # TODO: check if select() or accept() is a problem on large
         # SMP systems under Ruby 1.9.  Hundreds of native threads
@@ -66,7 +66,7 @@ module Rainbows
       end while G.alive
     end
 
-    def join_threads(threads)
+    def join_threads(threads) # :nodoc:
       G.quit!
       threads.delete_if do |thr|
         G.tick