Hi there!
Working with FME Desktop 16.1.2.1 in a rather complex FME Workspace I decided recently to reorganize the FME Workspace such that it would become a little less complex to maintain the Workspace.
Certain attribute values, that were used in multiple occasions in different parts within the Workspace, were before distributed based on FeatureMergers based on common attributes and attribute values (tempid = 1 for all incoming features) and making use of AttributeKeepers to keep the amount of data processing small and let only those attributes through that are actually needed. In that case the order of adding attributes to features is defined and this works splendid (but makes the FME Workspace perhaps a little more complex than needed and less elegant to read).
In order to simplify the Workspace I decided to use VariableSetters and VariableRetrievers throughout the Workspace such that less FeatureMergers and hence less connections are needed, simplifying the Workspace.
Now I am experiencing some problems. In at least one case a VariableRetriever is read before the Variable is set in a VariableSetter. Apparently certain logic within FME Workbench is missing (at least for FME Desktop 16.1.2.1) to first execute the VariableSetter and only afterwards any VariableRetrievers. In those cases the attributes are created without the required attribute values, resulting in this case in empty attributes and a problem in the chain of processing.
I am in search for ways to cope with this problem. I came up with the following workarounds:
* I could make use of the FeatureHolder and could be lucky that that would delay executing the VariableRetriever such that the VariableSetter is executed beforehand. Based on trial and error this could in cases work out. The need of multiple FeatureHolders within the Workspace would complicate the matter however as it is unknown beforehand which FeatureHolders are executed first;
* The order of Readers could be changed such that the order in which the processes are executed changes. Within the Workspace mostly FeatureReaders are used however, and as far as I know the order in which these are executed can not be set;
* FeatureMergers based on common attributes and attribute values (tempid = 1 for all features) could define the order in which the VariableRetrievers and VariableSetters are executed. However, this is undermining the goal to simplify the Workspace using less FeatureMergers and is therefore not a real solution.
I am looking forward for suggestions to cope with this problem. Meanwhile I partially will have to undo some of the work I did.
Best Regards, Jochgem Gunneman