In part 4 of this tutorial, you'll learn how to set up an FME Workspace to run automatically on a schedule.
In this scenario the goal is to have FME Server automatically run a workspace that extracts data from a database and refreshes a set of Shapefiles, on a daily basis.
We’ll make use of the CommunityMapping.fmw workspace already published to FME Server, which reads layers from a file geodatabase and writes out to one of four formats.
a) Click on the Manage Schedule button
This opens the Schedules page.
b) Click New to create a new schedule.
- Give the task a Name. Call it CommunityMappingData.
- Create a Category to put this task in: Production. Give it a description "Scheduled tasks which extract data from production database."
- Leave the default checkmark on next to Enabled
c) Set up the workspace details.
- select the repository the workspace belongs in (Server Tutorial)
- select the communitymapping.fmw workspace.
- for output format select Esri Shapefile.
- process all the layers in the workspace, so click on “Select All” under Feature Types to Read.
This workspace is to run daily at the same time, but for now set this up to run immediately and then every 5 seconds, just so we can see it in action right away.
a) Set up Test Schedule
- click Immediately
- set the repeat unit to SECOND
- set the interval to 5.
- keep Never checked for the End Date.
- click OK. Make a note of the current time.
b) See Results
Go to the Manage menu and select Jobs. Notice the CommunityMapping workspace has already run three times, and every 5 seconds.
c) Disable Current Scheduled Task.
Go to the Manage menu and select Schedules. Check the task just set up, and click on the Disable button to stop the current task.
a) Edit the task again.
- click on the CommunityMappingData row to start editing. Scroll down to the schedule section.
- this time select the workspace to start running tomorrow at 1:00 am.
- change the repeat unit to DAY
- change the interval to 1 for daily.
If desired, notifications can be set up to send upon successful or unsuccessful execution of the task. The Advanced Settings is where specific job settings can be entered. We’ll leave these for now.
b) Click Save.
We’ve now set up FME Server to perform a scheduled task.
1 Person is following this .