Question

Flow Control approach in FME workspace

  • 28 June 2019
  • 1 reply
  • 9 views

Badge +9
  • Contributor
  • 101 replies

Recently it occured to me, that I have to solve a set of seemingly similar control flow problems in FME quite often.

Starting point is a workspace which is re-used for different scenarios. A generic approach to solve a family of similar tasks.

Basic problem usually is the behaviour of transformers like Clipper, AppearanceSetter, and similar ones which need two (or more) different streams of features and produce a result which combines the data sets.

Clippers clip Clippees, Geometry is textured with rasterdata, ... you get the idea

Problem starts whenever one of the necessary datasets is missing.

E.g. the result stream of a processing may need clipping and goes into the Clippee port of the Clipper. If there are no Clippers available no output is produced.

So as a workaround I need to fumble around with a FeatureMerger and several helper transformers to let the resulting stream pass by the Clipper whenever there happens to be no clipping feature.

Or I need to avoid the AppearanceSetter if either geometry or texture is missing, a.s.o.

 

So it occurred to me that what I need here is some kind of conditional workflow control/steering. This kind of flow control would not depend on conditions to test on each feature but instead depends on the fact if certain streams deliver features or not.

What comes to mind is similarities to electrical circuit controls, like transistors, gates, etc.

I checked existing transformers of category "Workflows" both in basic FME and on FME Hub and found a small set of helpers: FeatureHolder, FeatureHolderExt, SignalInverter, Triggerer, ...

 

So I am thinking if I stumbled over a gap in FME functionality here or if I got lost in the task ...

Let me know if you can relate to this or what kind of solutions come to mind ...

 


1 reply

Userlevel 5
Badge +25

It does occor for me from time to time as well, especially when building solutions that might be used with changing source data in the future or depend on user input and generate something that goes directly to an end user.

Reply