camunda / camunda-bpm-platform

Flexible framework for workflow and decision automation with BPMN and DMN. Integration with Quarkus, Spring, Spring Boot, CDI.
https://camunda.com/
Apache License 2.0
4.05k stars 1.53k forks source link

Ensure that RPA jobs are not always started in the same environment for load balancing reasons #2448

Open ThorbenLindhauer opened 4 years ago

ThorbenLindhauer commented 4 years ago

This issue was imported from JIRA:

Field Value
JIRA Link CAM-12194
Reporter @mboskamp
Has restricted visibility comments false

Currently, the bridge starts new RPA jobs in the first environment returned by the UIPath API. Depending on how the result is sorted we might always choose the same environment.

We could either introduce load balancing in the bridge, which might need some sort of persistence or we could make the environment configurable per External Task (e.g. by extension property).

Alternative approach: Use queue mechanisms of RPA vendors, if supported. In UiPath, you can add items to specific queues instead of starting jobs directly. The orchestration then takes care of balancing the load. We could make this configurable as well either in the bridge or per RPA task via extension properties.

Links:

ThorbenLindhauer commented 3 years ago

This comment was imported from JIRA and written by user @tmetzke


We should also think about adding items to queues instead of starting jobs directly. When using the Queue, we receive a queue item instead of a specific job instance. This queue item can be supervised similarly to a job instance. Furthermore, a queue in UiPath allows to tie it to a specific environment that defines a certain bot process as well as a user on a specific machine. That way, the BPMN activity would still only reference a specific item (in this case a queue name) that takes care of all the load balancing itself (i.e., the queue might as well define multiple users on different physical machines to balance the load).