aboutsummaryrefslogtreecommitdiffstats
path: root/docs
diff options
context:
space:
mode:
authorJP Dillingham <jp@dillingham.me>2022-09-17 17:09:45 -0500
committerJP Dillingham <jp@dillingham.me>2022-09-17 17:09:45 -0500
commit9b505173b4c97330dd82c767509a27d945b42d4f (patch)
tree052f6bb616e9492c09efe6f1ecb874264e1e9f1b /docs
parentb94e10dc7ce688ce68cd1a1d9fcbfb04373a0937 (diff)
downloadslskd-9b505173b4c97330dd82c767509a27d945b42d4f.tar.gz
add an option to set the number of scan workers
Diffstat (limited to 'docs')
-rw-r--r--docs/config.md7
1 files changed, 7 insertions, 0 deletions
diff --git a/docs/config.md b/docs/config.md
index 0580baf5..19692fe3 100644
--- a/docs/config.md
+++ b/docs/config.md
@@ -166,9 +166,16 @@ Storing the cache on disk uses quite a bit less memory and allows the applicatio
The cache is stored in memory by default. If you find that the application uses too much memory or crashes with an `Out of Memory` exception, change this option to store the cache on disk.
+Scanning shares is an I/O intensive operation; all of the files and directories in each share have to be listed, and each file has to be read to gather metadata like length, bitrate, and sample rate. To speed things up, multiple 'workers'
+are used to allow metadata to be read from several files concurrently. The scan generally gets faster as additional workers are added, but each worker also adds additional I/O pressure and increases CPU and memory usage. At some number of workers
+performance will start to get worse as more are added. The optimal number of workers will vary from system to system, so if scan performance is important to you it will be a good idea to experiment to see what the optimal number is for your system.
+
+The default number of workers is 16.
+
| Command Line | Environment Variable | Description |
| ---------------------------- | -------------------------- | ------------------------------------------------------- |
| `--share-cache-storage-mode` | `SHARE_CACHE_STORAGE_MODE` | The type of storage to use for the cache (Memory, Disk) |
+| `--share-cache-workers` | `SHARE_CACHE_WORKERS` | The number of workers to use while scanning shares |
#### **YAML**
```yaml