I have created a FME workbench where it reads files from 5 different sources and writes it excel worksheet. Currently I run this process monthly why going clicking Run in FME. I would like to automate this process where it will run automatically 1st of the new month. Has anyone done something like this, if yes please let me know how to set one up.
Two ways of doing this:
With FME Desktop you can crate a batch file and publish that to the Windows Scheduler.
The other and nicer way is to use FME Server.
Information about FME Server can be found here: http://www.safe.com/fme/fme-server
As @erik_jan says, you can use FME Server. But what you can also do is use server in the cloud - i.e. FME Cloud. This would be a good scenario to use it, provided it can see the data being used.
You can set up your FME Cloud machine to only turn on at certain times, and then you can schedule the workspace to run at that time too.
So rather than buy FME Server you just pay when you need it. If the translation took an hour you would only need to use Server for one hour per month and the cost would be about $5-$10 a month (that's just my very rough estimate).
For more information check out this page and also you can contact us at Safe (look for the chat window at the bottom of that page).
Hi @ruby6,
@erik_jan did already provide you with the two possibilities. If you would like to chose the first possibility, this is the way to implement it.
1. Create a batch-file that will run your workspace. If your workspace doesn't accept parameters, the batch-file will look like this:
"C:\Program Files\FME\2016_1\fme.exe" "C:\temp\FME\runBatFile.fmw"
You can see the first path locates the fme.exe file. The second path locates the workspace. If you have to provide parameters, you can do so using key-value pairs:
https://knowledge.safe.com/articles/975/batch-proc...
2. Setup a sheduled task by opening the 'Task Sheduler' via de Windows start menu and 'Create Basic Task'. On the Trigger pane, chose for 'Monthly'. On the next pane you can specify when this action should be triggered exactly. Below you can find a suggestion.
On the pane with the name 'Action', you have to chose for the option to 'Run a program' and provide the link to the created bat-file.
When you arrive at the last pane 'Finish', you successfully created a sheduled task. This task will be listed in the active tasks. It might be a good idea to double click on the newly created task and check the different options in the Conditions and Settings panes. For example, there is an option to not run the task when the computer is not connected to AC power, or to run the task as soon as possible after a scheduled start is missed (because your computer was shut down)...
Is this an answer on your question?
Good luck!
Jeroen
@jeroenstiers gave a thorough answer. To do it without a batch file you just add the .fmw path directly in the scheduled task. On the Action screen where you Start a Program, click into Argument and type your file path like c:\\temp\\my.fmw
@jeroenstiers gave a thorough answer. To do it without a batch file you just add the .fmw path directly in the scheduled task. On the Action screen where you Start a Program, click into Argument and type your file path like c:\\temp\\my.fmw
Hi kurttowler, I am just wondering. Is it possible to provide values for published parameters using this method? I would guess something like a GET-request like structure could maybe work?
C:\\workspace.fmw?dataset=C:\\input.shp&nameResult;=resultData
Thank you everyone. I used the batch file to schedule the task and it worked. I am so happy. Than kyou so much everyone for your help
thank you so much, everyone for helping me with this question. I set a batch file to run and it worked great.