summaryrefslogtreecommitdiff
path: root/python/threadpool/README
diff options
context:
space:
mode:
authorDimitris Zlatanidis <d.zlatanidis@gmail.com>2014-01-06 22:25:08 +0100
committerErik Hanson <erik@slackbuilds.org>2014-01-07 11:13:07 -0600
commit08b3ed87ae3f4d48bba025bf3f3103f64cdc19c9 (patch)
tree9a9155ba884cb50906bcd731ceb2144d4f22898b /python/threadpool/README
parente8839eb2a3810236885e1e40e8e383081725485b (diff)
downloadslackbuilds-08b3ed87ae3f4d48bba025bf3f3103f64cdc19c9.tar.gz
python/threadpool: Added (object-oriented thread pool framework).
Signed-off-by: Matteo Bernardini <ponce@slackbuilds.org>
Diffstat (limited to 'python/threadpool/README')
-rw-r--r--python/threadpool/README13
1 files changed, 13 insertions, 0 deletions
diff --git a/python/threadpool/README b/python/threadpool/README
new file mode 100644
index 0000000000..1460b6122f
--- /dev/null
+++ b/python/threadpool/README
@@ -0,0 +1,13 @@
+A thread pool is an object that maintains a pool of worker threads to
+perform time consuming operations in parallel. It assigns jobs to the
+threads by putting them in a work request queue, where they are picked
+up by the next available thread. This then performs the requested
+operation in the background and puts the results in another queue.
+
+The thread pool object can then collect the results from all threads
+from this queue as soon as they become available or after all threads
+have finished their work. It's then possible to define callbacks to
+handle each result as it comes in.
+
+NOTE: This module is regarded as an extended example, not as a
+finished product. Feel free to adapt it too your needs.