This commit is contained in:
Ilkka Seppälä
2019-12-13 21:09:28 +02:00
parent 0335c61512
commit b2b1ba95eb
127 changed files with 282 additions and 450 deletions

View File

@ -5,8 +5,7 @@ folder: semaphore
permalink: /patterns/semaphore/
categories: Concurrency
tags:
- Java
- Difficulty-Intermediate
- Performance
---
## Also known as
@ -25,8 +24,8 @@ is called a binary semaphore.
## Applicability
Use a Semaphore when
* you have a pool of resources to allocate to different threads
* concurrent access to a resource could lead to a race condition
* You have a pool of resources to allocate to different threads
* Concurrent access to a resource could lead to a race condition
## Credits