Skip to main content
Solved

"conditional" parameters in Automation ?


vki
Contributor
Forum|alt.badge.img+7
  • Contributor

(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

Best answer by timatsafe

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.

View original
Did this help you find an answer to your question?

4 replies

vki
Contributor
Forum|alt.badge.img+7
  • Author
  • Contributor
  • July 24, 2024

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


TandraAtSafe
Safer
Forum|alt.badge.img+7

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? 


vki
Contributor
Forum|alt.badge.img+7
  • Author
  • Contributor
  • July 29, 2024

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)?


timatsafe
Safer
Forum|alt.badge.img+3
  • Safer
  • Best Answer
  • August 1, 2024

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


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings