You can issue follow-up tasks with the ThreadPool either manually by checking the results of tasks or automatically using a result callback …
Continue Reading about ThreadPool Follow-Up Tasks in Python →
Tutorials on the multiprocessing.pool.ThreadPool class for concurrency in Python.
by Jason Brownlee in ThreadPool
You can issue follow-up tasks with the ThreadPool either manually by checking the results of tasks or automatically using a result callback …
Continue Reading about ThreadPool Follow-Up Tasks in Python →
by Jason Brownlee in ThreadPool
Asynchronous tasks issued to the ThreadPool can fail silently. You can learn more about asynchronous tasks that fail silently in the ThreadPool by …
Continue Reading about ThreadPool Tasks Fail Silently (and how to fix it) →
by Jason Brownlee in ThreadPool
You can cancel all tasks in the ThreadPool if one task fails using a shared Event object. In this tutorial, you will discover how to cancel all …
Continue Reading about ThreadPool Stop All Tasks If One Task Fails in Python →
by Jason Brownlee in ThreadPool
You can safely stop tasks in the ThreadPool using a shared Event object. In this tutorial, you will discover how to safely stop tasks in the …
Continue Reading about ThreadPool Stop All Tasks in Python →
by Jason Brownlee in ThreadPool
You can get results from tasks in the ThreadPool using a callback or by calling AsyncResult.get(). In this tutorial, you will discover how to get …
Continue Reading about ThreadPool Get Results from Asynchronous Tasks →
by Jason Brownlee in ThreadPool
The ThreadPool will be closed automatically by the Python garbage collector if required. It will not prevent the program from exiting and the …
Continue Reading about Does the ThreadPool Stop Main From Exiting →
by Jason Brownlee in ThreadPool
Child worker threads are started automatically after creating an instance of the ThreadPool class. In this tutorial, you will discover when the …
Continue Reading about ThreadPool When Are Workers Started →
by Jason Brownlee in ThreadPool
You can get the details of the thread used to initialize worker threads and to execute tasks in the ThreadPool. Additionally, the ThreadPool uses …
Continue Reading about Details of Threads Used in ThreadPool in Python →
by Jason Brownlee in ThreadPool
You can get the name of a worker thread in the ThreadPool by calling threading.current_thread() and then accessing the "name" attribute. Worker …
Continue Reading about How to Get ThreadPool Worker Names in Python →
What if you could use thread pools to run many tasks concurrently right now, with just a very small change to your code?
The ThreadPool class provides easy-to-use thread-based concurrency.
There's just one problem. Few people know about it (or how to use it well).
Introducing: "Python ThreadPool Jump-Start".
A new book designed to teach you thread pools in Python step-by-step, super fast!