summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornanbor <nanbor@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1998-10-27 09:28:34 +0000
committernanbor <nanbor@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1998-10-27 09:28:34 +0000
commitcdf7138c328e742c055926ee1eacd0c2f3e7bb25 (patch)
tree6e17e3f2d029b55359e1f56847270b862fbc8841
parent21490bbe9145979beb451715e8c3e557740bd649 (diff)
downloadATCD-cdf7138c328e742c055926ee1eacd0c2f3e7bb25.tar.gz
Added a description section.
-rw-r--r--ace/TP_Reactor.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/ace/TP_Reactor.h b/ace/TP_Reactor.h
index 12307f21d8e..3dab62c2607 100644
--- a/ace/TP_Reactor.h
+++ b/ace/TP_Reactor.h
@@ -9,8 +9,24 @@
// = FILENAME
// TP_Reactor.h
//
+// = DESCRIPTION
+// TP_Reactor (ala, Thread Pool Reactor) uses the leader-follower
+// model to demultiplex requests among a bunch of threads.
+// Basically, when using thread pool reactor, one will pre-spawn a
+// _fixed_ number of threads. When you issue the run_event_loop ()
+// method, one of the thread will become the leader thread and wait
+// for an event. The other threads (followers) will be lined up
+// and waiting for their turns to become the leader. When an event
+// occurs, the leader will pick a follower to become the leader and
+// go on to handle the event. The consequence of using TP_Reactor
+// is the amortization of the costs used to creating threads. The
+// context switching cost will also reduce. More over, the total
+// resources used by threads are bounded (because there are only so
+// many threads.)
+//
// = AUTHOR
// Irfan Pyarali
+// Nanbor Wang
//
// ============================================================================