Learning outcomes from reading the book 'Learning Concurrency in Python' by Elliot Forbes - published by Packt
Go to file
Andrew Macmillan 12db9a813e update primefac func name 2021-01-30 13:42:27 +00:00
io_bottlenecks upload file 2021-01-30 13:41:44 +00:00
non_deterministic_threading upload file 2021-01-30 13:41:44 +00:00
single_process_vs_multi_process update primefac func name 2021-01-30 13:42:27 +00:00
single_thread_vs_multi_thread record and compare time to make 10 API requests 2020-12-31 12:31:45 +00:00
.gitignore update .gitignore 2020-12-31 12:30:03 +00:00
LICENSE Initial commit 2020-12-31 10:25:34 +00:00
Pipfile create pipenv virtual environment 2020-12-31 12:30:25 +00:00
Pipfile.lock create pipenv virtual environment 2020-12-31 12:30:25 +00:00
README.md Update README.md 2020-12-31 17:48:58 +00:00

README.md

Concurrency in Python

Learning outcomes from reading the book 'Learning Concurrency in Python' by Elliot Forbes - published by Packt

Brief Preamble

Python has several implementations that each handle concurrent programming in their own language specific way. Some popular examples are CPython (C), PyPy (Python), Jython (Java) and IronPython (.NET). The C and Python implementations have a thread locking mechanism included called the Global Interpreter Lock (GIL). The purpose of this mechanism is to stop multiple threads from executing code simultaneously. This creates thread-safe programs by avoiding race conditions and deadlock.

This GIL has caused numerous debates about the performance of the Python lanuguage when it comes to multithreaded programming, because it essentially reduces all programs to using a single thread. This book teaches us about threads, processes concurrency, parallelism and asynchronicity in Python implementations that use the GIL, and how we can write performant code that takes advantage of the benefit these concepts bring.