Long-lived processes pause | Tasks do not move forward in Work Manager

Status of a process in Work Manager of Admin UI is not updated when task is complete


Set the batch size of Work Manager to 1. It forces synchronization between the two threads. Perform the following steps to change the batch size:

Add Java options to JBoss

  1. Stop the JBoss application server.

  2. Open the [appserver root]/bin/standalone.bat (Windows) or standalone.sh (Linux or UNIX) in an editor and add the Java options -Dadobe.workmanager.allocate.max-batch-size=1

  3. Restart the server.

Add Java options to WebLogic

  1. Start the WebLogic Administration Console by typing http://[host name]:[port]/console in a web browser.

  2. Type the user name and password that you created for the WebLogic Server domain and click Log Under Change Center, click Lock & Edit.

  3. Under Domain Structure, click Environment > Servers and, in the right pane, click the managed server name.

  4. On the next screen, click the Configuration tab > Server Start tab.

  5. In the Arguments box, append the argument -Dadobe.workmanager.allocate.max-batch-size=1

  6. Click Save and then click Activate Changes.

  7. Restart WebLogic managed server.

Add Java options to WebSphere

  1. In the WebSphere Administrative Console navigation tree, click Servers > Server Types > WebSphere application servers.

  2. In the right pane, click the server name.

  3. Under Server Infrastructure, click Java and forms workflow > Process Definition.

  4. Under Additional Properties, click Java Virtual Machine.

  5. In the Generic JVM arguments box, type the arguments -Dadobe.workmanager.allocate.max-batch-size=1.

  6. Click OK or Apply, and then click Save directly to the master configuration.

Additional information

The default batch size of Work Manager is 10. It can cause a race condition between Work Manager threads. In the race, one thread updates a few work items to an in-progress state while the other thread fails to pick up all the items marked as in-progress and executes the items.