grabs a dataset from a rest endpoint and creates an in-memory Uipath database
grabs a dataset from a SQL database and creates an in-memory Uipath database
Loops through rows in one dataset - does a datatable lookup in the other data set - then loops through the fields to look for when the fields are different.
If they are different i append a new json blob to a string(stringa=stringa+‘new json’)
At the very end i save this json blob to a text file and push back to a rest endpoint
The datasets have maybe 15000 rows and 10 fields and the job takes many hours to run. How can I identify which activities are creating the slowness? the slowness is definitely in the loop and data comparison and not in the data collection or data pushing.
I would expect this in-memory comparison to happen much quicker. Appreciate any points in the right direction.
There is some overhead of processing activity In UiPath (Workflow Foundation). And if we use loop for large data, performance matter becomes apparent.
To solve this matter, we can reduce number of processing activity using LINQ or InvokeCode activity etc.
Enable the log to info or trace level in robot assistant
You can find the execution logs in %localappdata%\UiPath\Logs sorted by date. In these files you will see that there are the parameters: totalExecutionTimeInSeconds and totalExecutionTime which show the process time from start to end.
At the begining of each log line there is also the start time of each step, so you will get an idea of how long it took for each step.
For example, If we use ForEachRow for 15K records and activity’s overhead is assumed 50msec, it takes 750sec for only overhead.
On the other hands, if we use ForEach inside Invoke code, activity’s overhead is only 50msec. It can improve performance especially in case of large records