semaphore
/SEM-uh-for/ · noun · Development · Origin: 1965
Definitions
A synchronization primitive that controls access to a shared resource through a counter, allowing a specified number of threads to access the resource simultaneously. A binary semaphore (counter of 1) behaves like a mutex. Counting semaphores allow N concurrent accessors. Invented by Dijkstra, who also gave us the terms P (wait/acquire) and V (signal/release) from Dutch.
In plain English: A counter-based lock that controls how many things can access a shared resource at once — like a bouncer who only lets a certain number of people into a club.
Example: The connection pool uses a semaphore initialized to 20, so at most 20 threads can hold database connections simultaneously — the 21st blocks until one is released.