Hide Forgot
Description of problem: On Kie server, async nodes are not executed asynchronously, even when the Executor service is available. Version-Release number of selected component (if applicable): BPMS 6.2.0.GA How reproducible: Always reproducable Steps to Reproduce: 1. Install BPMS Kie Server 2. Start Kie Server 3. Make sure the Executor component is available and started In the logs: ---- 14:22:34,427 INFO [org.jbpm.executor.impl.ExecutorImpl] (ServerService Thread Pool -- 53) Starting Executor Component ... - Thread Pool Size: 1 - Interval: 3 SECONDS - Retries per Request: 3 ---- 4. Unzip and build the attached project (the project has a simple process with a async script node) ---- $ mvn clean install ---- 5. create a container on the kie-server for the project: HTTP POST http://localhost:8080/kie-server/services/rest/server/containers/async with payload ---- { "release-id" : { "group-id" : "org.jboss.btison", "artifact-id" : "async-test", "version" : "1.0" } } ---- 6. start an instance of the process HTTP POST http://localhost:8080/kie-server/services/rest/server/containers/async/processes/test.async-node/instances With payload: ---- {} ---- Actual results: In the kie server log: ---- 14:40:41,497 WARN [org.jbpm.workflow.instance.node.AsyncEventNodeInstance] (http-/127.0.0.1:8080-3) No async executor service found continuing as sync operation... 14:40:41,498 INFO [stdout] (http-/127.0.0.1:8080-3) In async node ---- Expected results: Async node is executed asynchronously. Additional info: Possible root cause: on kie-server, the Executor service is not added to the KModuleDeploymentService. As a result, when the RuntimeEnvironmentBuilder is bootstrapped (in KModuleDeploymentService.boostrapRuntimeEnvironmentBuilder()), the Executor service impl is not added to the Runtime environment. On business-central, the Executor service in injected through CDI in the KModuleDeploymentService. Kie-server does not use CDI.
Maciej, could you investigate this?
great catch Bernard! and you're right with missing executorService on deploymentService so you actually solve it as well. Remaining part for me was to write a test case. Once again, thanks a lot. PRs sent and being built before the merge...
fixed droolsjbpm-integration master: https://github.com/droolsjbpm/droolsjbpm-integration/commit/e75f30621b1bac91af4f0a347fa115f2e882e242 6.4.x: https://github.com/droolsjbpm/droolsjbpm-integration/commit/9539cc166edb6f1870e3068ad27197ba519d42b5
Verified in 6.3.0ER3