Welcome to getting started with FME Server.
This tutorial gives you hands-on experience with this component of the FME data integration platform.
In previous videos in this series we learned how to publish a workspace to FME Server,
and run it from the web interface.
We also learned to create a self-serve data access portal with user parameters and the Data Download service.
Now let's learn how to schedule a task using FME Server.
In this video we build a new Automation in FME server,
we set up the Automation trigger as a scheduled task,
we set up the Automation action to run a workspace,
we test the Automation and then we set up an actual schedule.
As with the previous video, sample data and workspaces
are attached to the main landing page for this tutorial on knowledge.safe.com
Now let's start by opening up the FME Server web interface
Open the FME server web interface and log in with the author account.
Choose Automations > Build from the main menu.
Yhe automations page has a Getting Started panel that helps us create a new Automation.
Click on the tab labeled Build then select Create New.
This creates a basic Automation.
It currently includes an undefined trigger and no action.
Let's start by setting up the Trigger.
Click on the trigger object to open the details panel.
Select Schedule Initiated as the trigger event.
In the parameters that appear leave the "Schedule Type" as "Repeat on Interval"
Under "Repeat Every" enter 1, and then select "Minutes" from the drop-down.
"Start Immediately" is checked by default. Leave this as- is and click Apply.
Your Trigger is now configured to fire every minute, although the automation isn't yet activated,
and also still requires an action to carry out.
Well, let's take care of that next.
Click the light grey object labeled "Next Action" to open its details panel.
Select "Run a Workspace" as the action to carry out.
In the same panel, now select the Community Mapping workspace from the Server Tutorial repository.
We can also set the user parameters for this workspace,
so select ESRI Shapefile as the output format.
Select all of the items listed under Feature Types to Read,
so that all of the source data is processed.
Click the Apply button to apply these changes to the action.
The Automation is now set up, but it is neither saved nor activated.
To do so first click Menu > Save As on the Automations panel menu.
Enter a name such as ScheduledShapeUpdater,
and a tag such as Server Tutorial.
Click OK .
Now click the Start Automation button.
The Automations canvas turns gray and a message tells us that the Automation is running.
Since the Start Immediately option was checked, the Automation is now triggered straightaway,
and every minute after that.
Let's confirm that.
On the main menu select Automations > Manage.
This opens a page where all Automations are listed.
Select the newly created Automation by clicking the checkbox next to it.
Now select Actions > View Log File from the in-page menu.
The Automation log lists processes initiated by your Automation,
including jobs sent to the FME engine.
Time stamps are displayed by clicking on the clock icon on the upper right of the log panel.
To aid archiving or troubleshooting, a Download button saves the log to a file.
A Clear button empties the log and is useful when the log is archived or the Automation is edited.
Return to the Manage Automations page,
and this time select View Triggered Jobs from the in-page menu.
This displays a higher-level list of jobs run by the selected Automations.
You may select any listed job to view its individual FME log file.
Like Automation logs, a button exists to download these logs for archiving or sharing.
Now we know that the automation is working,
we can set a more realistic - say daily - schedule, for this task.
However, Automations must be deactivated before they can be edited.
So...
Return to the Automations build page and click the ScheduledShapeUpdater Automation to open it.
Now click the button labeled Stop Automation
An alternative method to stop an Automation,
is through the menu options under the Manage page.
Click on the Trigger object to view the details panel.
Change the time period from minutes to days,
and then set a start date of tomorrow at 1am.
To do so select the date and time using the calendar widget.
Apply the changes and then click Start Automation.
If you wish to test the Automation at this - or at any other - point,
click on the Schedule object again to open the details panel.
Although you cannot make changes while it is active, you can click the Trigger button to run it immediately.
So... click the Trigger button,
and then check the Automation log to confirm that the workspace was started correctly.
Thank you for viewing part four (the final part) of this tutorial.
We hope you found these Getting Started tutorials useful.
If you have any questions about using FME Server,
please visit our online user forums or read the FME server documentation.
Or... to take your FME server use to the next level,
you can attend live, online training by visiting our training page at safe.com/training
Thank you.