From 84fca6d46e2a9577fe6d4faf9f7431880fd423fd Mon Sep 17 00:00:00 2001 From: Srikanth Padakanti Date: Tue, 23 Sep 2025 14:35:08 -0500 Subject: [PATCH 01/10] Add support for a ForkJoinPool type - 18674 Signed-off-by: Srikanth Padakanti --- .../thread-pool-settings.md | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/_install-and-configure/configuring-opensearch/thread-pool-settings.md b/_install-and-configure/configuring-opensearch/thread-pool-settings.md index 63ac493c8a..6638142fa0 100644 --- a/_install-and-configure/configuring-opensearch/thread-pool-settings.md +++ b/_install-and-configure/configuring-opensearch/thread-pool-settings.md @@ -61,6 +61,18 @@ Scaling thread pools support the following settings: - `thread_pool..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. + +ForkJoin thread pools support the following settings: + +- `thread_pool..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. +- `thread_pool..async_mode` (Static, boolean): If set to `true`, uses async mode for ForkJoinPool scheduling. +- `thread_pool..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. + ## Example configurations To configure a fixed thread pool, update the configuration file as follows: @@ -84,6 +96,17 @@ thread_pool: ``` {% include copy.html %} +To configure a ForkJoin thread pool, update the configuration file as follows: + +```yaml +thread_pool: + fork_join: + parallelism: 8 + async_mode: true + queue_size: 1000 +``` +{% include copy.html %} + To set a custom processor count, update the configuration file as follows: ```yaml From 830ee7519c4fa06a60030bed75ae94617b5c7848 Mon Sep 17 00:00:00 2001 From: Srikanth Padakanti Date: Tue, 23 Sep 2025 17:49:12 -0500 Subject: [PATCH 02/10] Add support for a ForkJoinPool type - 18674 Signed-off-by: Srikanth Padakanti --- .../configuring-opensearch/thread-pool-settings.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/_install-and-configure/configuring-opensearch/thread-pool-settings.md b/_install-and-configure/configuring-opensearch/thread-pool-settings.md index 6638142fa0..45dcad237f 100644 --- a/_install-and-configure/configuring-opensearch/thread-pool-settings.md +++ b/_install-and-configure/configuring-opensearch/thread-pool-settings.md @@ -102,8 +102,6 @@ To configure a ForkJoin thread pool, update the configuration file as follows: thread_pool: fork_join: parallelism: 8 - async_mode: true - queue_size: 1000 ``` {% include copy.html %} From 09e8a5bdf7dfcd4d8d321129f8e7dd18e9723b86 Mon Sep 17 00:00:00 2001 From: Srikanth Padakanti Date: Mon, 6 Oct 2025 11:03:16 -0500 Subject: [PATCH 03/10] Update _install-and-configure/configuring-opensearch/thread-pool-settings.md Co-authored-by: kolchfa-aws <105444904+kolchfa-aws@users.noreply.github.com> Signed-off-by: Srikanth Padakanti --- .../configuring-opensearch/thread-pool-settings.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/_install-and-configure/configuring-opensearch/thread-pool-settings.md b/_install-and-configure/configuring-opensearch/thread-pool-settings.md index 45dcad237f..e066e276c7 100644 --- a/_install-and-configure/configuring-opensearch/thread-pool-settings.md +++ b/_install-and-configure/configuring-opensearch/thread-pool-settings.md @@ -63,7 +63,7 @@ Scaling thread pools support the following settings: ### 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. +Fork-join thread pools use the Java `ForkJoinPool` to provide efficient parallelism for workloads that benefit from work stealing and task splitting. This is useful for compute-intensive operations. In OpenSearch, fork-join thread pools support features that rely on parallel computation, such as the [OpenSearch jVector plugin](https://github.com/opensearch-project/opensearch-jvector), which accelerates index builds. ForkJoin thread pools support the following settings: From b17e1b53d424c54175295fa02282bf0f030456a4 Mon Sep 17 00:00:00 2001 From: Srikanth Padakanti Date: Mon, 6 Oct 2025 11:03:32 -0500 Subject: [PATCH 04/10] Update _install-and-configure/configuring-opensearch/thread-pool-settings.md Co-authored-by: kolchfa-aws <105444904+kolchfa-aws@users.noreply.github.com> Signed-off-by: Srikanth Padakanti --- .../configuring-opensearch/thread-pool-settings.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/_install-and-configure/configuring-opensearch/thread-pool-settings.md b/_install-and-configure/configuring-opensearch/thread-pool-settings.md index e066e276c7..9ef5b0a576 100644 --- a/_install-and-configure/configuring-opensearch/thread-pool-settings.md +++ b/_install-and-configure/configuring-opensearch/thread-pool-settings.md @@ -65,7 +65,7 @@ Scaling thread pools support the following settings: Fork-join thread pools use the Java `ForkJoinPool` to provide efficient parallelism for workloads that benefit from work stealing and task splitting. This is useful for compute-intensive operations. In OpenSearch, fork-join thread pools support features that rely on parallel computation, such as the [OpenSearch jVector plugin](https://github.com/opensearch-project/opensearch-jvector), which accelerates index builds. -ForkJoin thread pools support the following settings: +Fork-join thread pools support the following settings: - `thread_pool..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. - `thread_pool..async_mode` (Static, boolean): If set to `true`, uses async mode for ForkJoinPool scheduling. From 83446dc69db5aae29cc88c21c7443135c428493b Mon Sep 17 00:00:00 2001 From: Srikanth Padakanti Date: Mon, 6 Oct 2025 11:03:50 -0500 Subject: [PATCH 05/10] Update _install-and-configure/configuring-opensearch/thread-pool-settings.md Co-authored-by: kolchfa-aws <105444904+kolchfa-aws@users.noreply.github.com> Signed-off-by: Srikanth Padakanti --- .../configuring-opensearch/thread-pool-settings.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/_install-and-configure/configuring-opensearch/thread-pool-settings.md b/_install-and-configure/configuring-opensearch/thread-pool-settings.md index 9ef5b0a576..d363878831 100644 --- a/_install-and-configure/configuring-opensearch/thread-pool-settings.md +++ b/_install-and-configure/configuring-opensearch/thread-pool-settings.md @@ -67,7 +67,7 @@ Fork-join thread pools use the Java `ForkJoinPool` to provide efficient parallel Fork-join thread pools support the following settings: -- `thread_pool..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. +- `thread_pool..parallelism` (Static, integer): Sets the target parallelism level (number of worker threads) for the pool. Typically, this value matches the number of available processors but can be tuned for specific workloads. - `thread_pool..async_mode` (Static, boolean): If set to `true`, uses async mode for ForkJoinPool scheduling. - `thread_pool..queue_size` (Static, integer): Sets the size of the submission queue for tasks. Can be set to `-1` for unbounded. From a697730d97626b71e0bb9b4c9901654399760251 Mon Sep 17 00:00:00 2001 From: Srikanth Padakanti Date: Mon, 6 Oct 2025 11:04:07 -0500 Subject: [PATCH 06/10] Update _install-and-configure/configuring-opensearch/thread-pool-settings.md Co-authored-by: kolchfa-aws <105444904+kolchfa-aws@users.noreply.github.com> Signed-off-by: Srikanth Padakanti --- .../configuring-opensearch/thread-pool-settings.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/_install-and-configure/configuring-opensearch/thread-pool-settings.md b/_install-and-configure/configuring-opensearch/thread-pool-settings.md index d363878831..29638802e5 100644 --- a/_install-and-configure/configuring-opensearch/thread-pool-settings.md +++ b/_install-and-configure/configuring-opensearch/thread-pool-settings.md @@ -68,7 +68,7 @@ Fork-join thread pools use the Java `ForkJoinPool` to provide efficient parallel Fork-join thread pools support the following settings: - `thread_pool..parallelism` (Static, integer): Sets the target parallelism level (number of worker threads) for the pool. Typically, this value matches the number of available processors but can be tuned for specific workloads. -- `thread_pool..async_mode` (Static, boolean): If set to `true`, uses async mode for ForkJoinPool scheduling. +- `thread_pool..async_mode` (Static, Boolean): If set to `true`, uses the asynchronous mode for fork-join pool scheduling. - `thread_pool..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. From 833f6841fa9a3851e7b36c37c3af2733726e0a7d Mon Sep 17 00:00:00 2001 From: Srikanth Padakanti Date: Mon, 6 Oct 2025 11:04:32 -0500 Subject: [PATCH 07/10] Update _install-and-configure/configuring-opensearch/thread-pool-settings.md Co-authored-by: kolchfa-aws <105444904+kolchfa-aws@users.noreply.github.com> Signed-off-by: Srikanth Padakanti --- .../configuring-opensearch/thread-pool-settings.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/_install-and-configure/configuring-opensearch/thread-pool-settings.md b/_install-and-configure/configuring-opensearch/thread-pool-settings.md index 29638802e5..509a72ed2c 100644 --- a/_install-and-configure/configuring-opensearch/thread-pool-settings.md +++ b/_install-and-configure/configuring-opensearch/thread-pool-settings.md @@ -69,7 +69,7 @@ Fork-join thread pools support the following settings: - `thread_pool..parallelism` (Static, integer): Sets the target parallelism level (number of worker threads) for the pool. Typically, this value matches the number of available processors but can be tuned for specific workloads. - `thread_pool..async_mode` (Static, Boolean): If set to `true`, uses the asynchronous mode for fork-join pool scheduling. -- `thread_pool..queue_size` (Static, integer): Sets the size of the submission queue for tasks. Can be set to `-1` for unbounded. +- `thread_pool..queue_size` (Static, integer): Sets the size of the submission queue for tasks. Set this value to `-1` for unbounded queue size. ForkJoin thread pools are currently used in features leveraging parallel computation, such as jVector. From 63dfec7d28273f032b987b111027760e02993b61 Mon Sep 17 00:00:00 2001 From: Srikanth Padakanti Date: Mon, 6 Oct 2025 11:04:53 -0500 Subject: [PATCH 08/10] Update _install-and-configure/configuring-opensearch/thread-pool-settings.md Co-authored-by: kolchfa-aws <105444904+kolchfa-aws@users.noreply.github.com> Signed-off-by: Srikanth Padakanti --- .../configuring-opensearch/thread-pool-settings.md | 1 - 1 file changed, 1 deletion(-) diff --git a/_install-and-configure/configuring-opensearch/thread-pool-settings.md b/_install-and-configure/configuring-opensearch/thread-pool-settings.md index 509a72ed2c..7e49df793b 100644 --- a/_install-and-configure/configuring-opensearch/thread-pool-settings.md +++ b/_install-and-configure/configuring-opensearch/thread-pool-settings.md @@ -71,7 +71,6 @@ Fork-join thread pools support the following settings: - `thread_pool..async_mode` (Static, Boolean): If set to `true`, uses the asynchronous mode for fork-join pool scheduling. - `thread_pool..queue_size` (Static, integer): Sets the size of the submission queue for tasks. Set this value to `-1` for unbounded queue size. -ForkJoin thread pools are currently used in features leveraging parallel computation, such as jVector. ## Example configurations From b6cf41430212c7694b3df6dcd1620715742a7bb3 Mon Sep 17 00:00:00 2001 From: Srikanth Padakanti Date: Mon, 6 Oct 2025 11:05:21 -0500 Subject: [PATCH 09/10] Update _install-and-configure/configuring-opensearch/thread-pool-settings.md Co-authored-by: kolchfa-aws <105444904+kolchfa-aws@users.noreply.github.com> Signed-off-by: Srikanth Padakanti --- .../configuring-opensearch/thread-pool-settings.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/_install-and-configure/configuring-opensearch/thread-pool-settings.md b/_install-and-configure/configuring-opensearch/thread-pool-settings.md index 7e49df793b..bc19f9b206 100644 --- a/_install-and-configure/configuring-opensearch/thread-pool-settings.md +++ b/_install-and-configure/configuring-opensearch/thread-pool-settings.md @@ -95,7 +95,7 @@ thread_pool: ``` {% include copy.html %} -To configure a ForkJoin thread pool, update the configuration file as follows: +To configure a fork-join thread pool, update the configuration file as follows: ```yaml thread_pool: From 257fb5562943c10de35a7f6b6f45cc3a78a95d35 Mon Sep 17 00:00:00 2001 From: Nathan Bower Date: Thu, 9 Oct 2025 12:17:14 -0400 Subject: [PATCH 10/10] Update _install-and-configure/configuring-opensearch/thread-pool-settings.md Co-authored-by: kolchfa-aws <105444904+kolchfa-aws@users.noreply.github.com> Signed-off-by: Nathan Bower --- .../configuring-opensearch/thread-pool-settings.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/_install-and-configure/configuring-opensearch/thread-pool-settings.md b/_install-and-configure/configuring-opensearch/thread-pool-settings.md index bc19f9b206..6d5d35f02c 100644 --- a/_install-and-configure/configuring-opensearch/thread-pool-settings.md +++ b/_install-and-configure/configuring-opensearch/thread-pool-settings.md @@ -61,7 +61,9 @@ Scaling thread pools support the following settings: - `thread_pool..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) +### Fork-join thread pool +**Introduced 3.2** +{: .label .label-purple } Fork-join thread pools use the Java `ForkJoinPool` to provide efficient parallelism for workloads that benefit from work stealing and task splitting. This is useful for compute-intensive operations. In OpenSearch, fork-join thread pools support features that rely on parallel computation, such as the [OpenSearch jVector plugin](https://github.com/opensearch-project/opensearch-jvector), which accelerates index builds.