Skip to main content
Solved

"conditional" parameters in Automation ?

  • 24 July 2024
  • 4 replies
  • 38 views

(We use FME Flow 2024.0.2.1)
I have an automation with about 20 actions. In the first action, a folder is read. The files it contains are the input for the other actions (written out with a automation writer, input parameter for the actions: route.xy)
However, it should also be possible to start the automation with the manual trigger and specify a file as a parameter, which is then used as input in the subsequent actions.
But this means that the input parameter for the other actions is not route.xy, but manual.xy.
Is there a way to set the input parameter for the individual actions so that the correct path is used in each case (route.xy or manual.xy)? 
Or do I have to duplicate all actions and set route.xy for one half and manual.xy for the other (after the manual trigger)?

Thanks, Vera

4 replies

Badge +7

Edit:
the parameters should be automation.xy (automation-Writer) vs manual.xy (manual trigger)

Userlevel 1
Badge +6

Hi @vki I’m having trouble visualizing the automation and trigger set up you’re talking about. Are you able to share a screenshot of the automation? 

Badge +7

The workspace A018a_Prd… needs a filepath as input-parameter. The automation is run with a scheduler that triggers a workspace, that reads a directory with files in it. The paths of those files are passed through the automation writer to the A018a_Prd-Workspace. 

However, it should also be possible to run the automation with a manual trigger. The user is prompted to enter a file path, which is then used in the A018a_Prd... workspace. (manual-parameter). 

This means, depending on whether the automation is run with the scheduler or with the manual trigger, the information that must be entered for the file path parameter in the A018a_Prd workspace changes.

If I run the automation with the manual trigger without changing the parameter in A018a_Prd, I get the following errors:

java.io.FileNotFoundException: {route.Filepfad.filepfad} (The system cannot find the file specified)
{route.Filepfad.filepfad} (The system cannot find the file specified)

Is there a way to use the manual trigger in such a case, or do I have to copy the automation and set all parameters new (to the manual parameter)?

Userlevel 1
Badge +3

Hi @vki,

There’s no way to dynamically change workspace parameters like that so you would have to copy the automation and set the parameters in the workspace to the manual parameter.

Reply