Skip to main content

Issues related to OOM errors

To investigate whether your issue is caused by an out-of-memory (OOM) error, act as follows:

Identify OOM

You can identify an OOM error by the following key traces:

  • An RPA Worker stops or restarts in the middle of execution.
  • You get com.workfusion.spa.core.execution.api.task.GenericTaskFailedException: exceeded task processing retry count; event logs include an exception confirming three retry attempts.

Investigate

To investigate an OOM issue, follow the steps below:

  1. Configure worker.bat or bot-agent-unit.yml to generate OOM heap dumps. If the dumps are generated, the issue relates to OOM.
  2. Analyze the dumps to identify the classes consuming the most memory.
  3. Configure additional logging in your BP to find the last code part executed before OOM.

Find solution

To address the issue, apply one of the following solutions:

  • Increase the -Xms and -Xmx parameters in worker.bat or bot-agent-unit.yml to give Java more available memory.
  • If the heap dump shows memory leaks in third-party libraries or the customer's code, try to implement the code in another way.
  • Analyze the logic you're executing on the RPA server. Probably, you can implement it in a less memory-consuming way.

Read also: