Skip to content
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,18 @@

- `thread_pool.<pool_name>.keep_alive` (Static, time unit): Determines how long idle threads are kept in the pool before being terminated. Threads above the core size are terminated after this period of inactivity.

### ForkJoin thread pool (New in OpenSearch 3.2)

ForkJoin thread pools utilize the Java `ForkJoinPool` to provide efficient parallelism for workloads that benefit from work stealing and task splitting. This is useful for compute-intensive operations, such as those used in OpenSearch jVector for faster index buildup.

Check failure on line 66 in _install-and-configure/configuring-opensearch/thread-pool-settings.md

View workflow job for this annotation

GitHub Actions / style-job

[vale] reported by reviewdog 🐶 [OpenSearch.Spelling] Error: jVector. If you are referencing a setting, variable, format, function, or repository, surround it with tic marks. Raw Output: {"message": "[OpenSearch.Spelling] Error: jVector. If you are referencing a setting, variable, format, function, or repository, surround it with tic marks.", "location": {"path": "_install-and-configure/configuring-opensearch/thread-pool-settings.md", "range": {"start": {"line": 66, "column": 236}}}, "severity": "ERROR"}

ForkJoin thread pools support the following settings:

- `thread_pool.<pool_name>.parallelism` (Static, integer): Sets the target parallelism level (number of worker threads) for the pool. This typically matches the number of available processors but can be tuned for specific workloads.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do any of these settings have defaults? If so, please list the defaults in the form "Default is <>".

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes non zero. Minimum has to be 1. Thanks.

- `thread_pool.<pool_name>.async_mode` (Static, boolean): If set to `true`, uses async mode for ForkJoinPool scheduling.

Check failure on line 71 in _install-and-configure/configuring-opensearch/thread-pool-settings.md

View workflow job for this annotation

GitHub Actions / style-job

[vale] reported by reviewdog 🐶 [Vale.Terms] Use 'Boolean' instead of 'boolean'. Raw Output: {"message": "[Vale.Terms] Use 'Boolean' instead of 'boolean'.", "location": {"path": "_install-and-configure/configuring-opensearch/thread-pool-settings.md", "range": {"start": {"line": 71, "column": 49}}}, "severity": "ERROR"}

Check failure on line 71 in _install-and-configure/configuring-opensearch/thread-pool-settings.md

View workflow job for this annotation

GitHub Actions / style-job

[vale] reported by reviewdog 🐶 [OpenSearch.Spelling] Error: async. If you are referencing a setting, variable, format, function, or repository, surround it with tic marks. Raw Output: {"message": "[OpenSearch.Spelling] Error: async. If you are referencing a setting, variable, format, function, or repository, surround it with tic marks.", "location": {"path": "_install-and-configure/configuring-opensearch/thread-pool-settings.md", "range": {"start": {"line": 71, "column": 28}}}, "severity": "ERROR"}
- `thread_pool.<pool_name>.queue_size` (Static, integer): Sets the size of the submission queue for tasks. Can be set to `-1` for unbounded.

ForkJoin thread pools are currently used in features leveraging parallel computation, such as jVector.

Check failure on line 74 in _install-and-configure/configuring-opensearch/thread-pool-settings.md

View workflow job for this annotation

GitHub Actions / style-job

[vale] reported by reviewdog 🐶 [OpenSearch.Spelling] Error: jVector. If you are referencing a setting, variable, format, function, or repository, surround it with tic marks. Raw Output: {"message": "[OpenSearch.Spelling] Error: jVector. If you are referencing a setting, variable, format, function, or repository, surround it with tic marks.", "location": {"path": "_install-and-configure/configuring-opensearch/thread-pool-settings.md", "range": {"start": {"line": 74, "column": 95}}}, "severity": "ERROR"}

## Example configurations

To configure a fixed thread pool, update the configuration file as follows:
Expand All @@ -84,6 +96,15 @@
```
{% include copy.html %}
To configure a ForkJoin thread pool, update the configuration file as follows:
```yaml
thread_pool:
fork_join:
parallelism: 8
```
{% include copy.html %}
To set a custom processor count, update the configuration file as follows:
```yaml
Expand Down
Loading