all index.md files renamed to README.md for more compatibility with github

This commit is contained in:
slawiko
2016-03-20 11:50:21 +03:00
parent 528d179efe
commit bd1b65276e
71 changed files with 34 additions and 34 deletions

25
thread-pool/README.md Normal file
View File

@ -0,0 +1,25 @@
---
layout: pattern
title: Thread Pool
folder: thread-pool
permalink: /patterns/thread-pool/
categories: Concurrency
tags:
- Java
- Difficulty-Intermediate
- Performance
---
## Intent
It is often the case that tasks to be executed are short-lived and
the number of tasks is large. Creating a new thread for each task would make
the system spend more time creating and destroying the threads than executing
the actual tasks. Thread Pool solves this problem by reusing existing threads
and eliminating the latency of creating new threads.
![alt text](./etc/thread-pool.png "Thread Pool")
## Applicability
Use the Thread Pool pattern when
* you have a large number of short-lived tasks to be executed in parallel