Will it be a best practice to call another process(start another job) from one process?

Hi There,

Good Day!

I have 3 processes and 1 queue.

  1. Dispatcher - which loads the items into the queue. (Time Trigger)
  2. Performer - which processes the loaded item from the queue. (Queue Trigger)
  3. Reporter - It creates and generates the report from other applications. (Time Trigger - After 4 hours of performer as sometimes it took 3 to 4 hours to complete the loaded items)

Question:

Right now, the Reporter is Time base trigger. However, we want to automatically execute the Reporter - once the performer completes the job(Therefore, we do not want to do unnecessary wait once the performer completes the job).

Will it be the best practice to call the start job activity for the Reporter in the Performer at the last of the End Process stage?
or
What is the best way to handle this situation(with best practice) and execute the Reporter once the performer completes the job.?

Thank you in advance.

-With Best Regards,
Malak Dudhia

1 Like

Starting the job from Performer is a fine way to solve it, I’ve done likewise in my automations.

Thank you for the help!

I would create a queue for the Reporter and have the Performer add an item to that queue when it finishes. Then a simple queue trigger kicks off the Reporter.

Thank you for the help!

Is there any way we can call the Reporter trigger from the process itself? and how feasible it is.

No, but there would be no need to. If you just want to directly start the Reporter from the Performer, use the Start Job activity.

However, that wouldn’t be my preference because with a queue in between them and a queue trigger starting the Performer, it’s easier to control. For example, you can then control on which server/user the Reporter runs, without touching the Performer code.

Yes, calling the Start Job activity for the Reporter in the Performer at the last of the End Process stage is a good way to handle the situation and execute the Reporter once the Performer completes the job. This is a common practice in UiPath, and it is a best practice because it ensures that the Reporter will only be executed once the Performer has finished processing the items in the queue.

Reason is Dispatcher process loads items into the queue. The Performer process processes the items in the queue. At the end of the Performer process, the Start Job activity is used to start the Reporter process.
The Reporter process will then generate the report from other applications.

There are many ways to trigger the process I have answered in detail in another post of yours

Hope this helps

Cheers @malak.dudhia

1 Like

Thank you for your reply and help!

I already used the start job activity but I want to run the process on a specific VM and robot account.

With Start Job, it runs on any available VM.

Any solution for it?

This was already suggested:

If you want to use Start Job, you probably would have to either do some configurations (eg. creating subfolder that contains just the robot you want to run with), or you could use Orchestrator API to start the job (with Orchestrator HTTP request), which I think could allow for more granular options.

Yes ofcourse
We can

If you want to run the process on a specific VM and robot account using the Start Job activity, you can follow these steps:

  1. In your UiPath Orchestrator, make sure that the specific VM you want to run the process on is correctly set up and configured with the robot account you prefer. Ensure that the robot account has the necessary permissions and access rights.
  2. Create a process in Orchestrator that is designed to run on the specific VM and robot account. This process should contain your Reporter logic.
  3. In the Start Job activity, you can specify the environment and specific robot account you want to use. When using the Start Job activity, set the Environment property to the environment that includes the specific VM, and select the desired robot account in the Robot property. This will ensure that the job is executed on the specified VM and robot account.
  4. Trigger the Start Job activity as you have been doing to run the Reporter process.

By specifying the environment and robot account in the Start Job activity, you can ensure that the process runs on the specific VM and robot account you desire. This way, you have control over the execution environment.

Ensure that the robot account and VM are correctly set up and licensed in Orchestrator to avoid any issues with running the process on the specified VM.

Cheers @malak.dudhia

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.