docs: improve documentation
[poolifier.git] / docs / worker-choice-strategies.md
similarity index 88%
rename from src/pools/selection-strategies/README.md
rename to docs/worker-choice-strategies.md
index 95eee0079f6bbbb7d4bdb37c7b7cf665c076d1f4..0a06627951661e7c803cc15f5a611ebfaa29b4ce 100644 (file)
@@ -1,9 +1,18 @@
 # Worker choice strategies
 
-All duration or timestamp are expressed in milliseconds.
+## Table of contents
+
+- [Strategies](#strategies)
+  - [Fair share](#fair-share)
+  - [Weighted round robin](#weighted-round-robin)
+  - [Interleaved weighted round robin](#interleaved-weighted-round-robin)
+- [Statistics](#statistics)
+  - [Median](#median)
 
 ## Strategies
 
+All duration or timestamp are expressed in milliseconds.
+
 ### Fair share
 
 Its goal is to distribute the load evenly across all workers. To achieve this, the strategy keeps track of the average task execution time for each worker and assigns the next task to the worker with the lowest task end prediction time: `task_end_prediction = max(current_time, task_end_prediction) + average_task_execution_time`.