From c9c0feec08ff1fe90cae9d6cac2117dc887dbe73 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joaqu=C3=ADn?= Date: Wed, 15 Jan 2025 16:09:38 +0100 Subject: [PATCH] feat(docs): add queue capacity property for fetch and lock long polling Related to https://github.com/camunda/camunda-bpm-platform/issues/4885 --- .../process-engine/external-tasks.md | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/content/user-guide/process-engine/external-tasks.md b/content/user-guide/process-engine/external-tasks.md index 91dc3bd113..eaa52ecc9e 100644 --- a/content/user-guide/process-engine/external-tasks.md +++ b/content/user-guide/process-engine/external-tasks.md @@ -110,7 +110,7 @@ Please also see the {{< restref page="fetchAndLock" text="REST API documentation #### Unique Worker Request By default, multiple workers can use the same `workerId`. In order to ensure `workerId` uniqueness on server-side, the -'Unique Worker Request' flag can be activated. This configuration flag effects only long-polling requests and not ordinary +'Unique Worker Request' flag can be activated. This configuration flag affects only long-polling requests and not ordinary 'Fetch and Lock' requests. If the 'Unique Worker Request' flag is activated, pending requests with the same `workerId` are cancelled when a new request is received. @@ -129,6 +129,22 @@ consider the following configuration snippet: ``` +#### Blocking Queue Capacity +By default, the blocking queue of long-polling 'Fetch and Lock' requests has a capacity of 200, meaning that exceeding this number of requests will return an error. This value can be changed by setting the `fetch-and-lock-queue-capacity` property as a context parameter in the `engine-rest/WEB-INF/web.xml` file of the *engine-rest* artifact. If this property is absent or its value invalid, the default value will be used. + +Please consider the following configuration snippet: + +```xml + + + + fetch-and-lock-queue-capacity + 250 + + + +``` + ## Java API The entry point to the Java API for external tasks is the `ExternalTaskService`. It can be accessed via `processEngine.getExternalTaskService()`.