I have an automation setup that monitors a directory for XML files on create and modify. Once the automation is triggered it passes the file to a workbench I published. The work bench automation reads the XML file and the ArcGIS SDE feature class and performs a feature merger to see if the unique key already exists(if the key doesn't exist the xml record gets inserted to an ArcGIS SDE Feature Class. If the key does exist the record gets updated through a change detector.)
Â
I ran into a problem where the FME Server job must have been triggered twice where the second job was created 7 seconds after the first. The first time on create trigger the record was inserted properly but on the second modify trigger when the work bench runs it created a duplicate record instead of updating the existing.
Â
I suspect this happened because the first job ran but didn't finish before the second job began. Is there a workflow I can follow in preventing this from happening?
Â
I would like the automation to run as the first record in will be the first out but I do not know how to accomplish it.