Unit 4 Exercise 11
Exercise 11: Windows File Arrival
Objective:
To use File Arrival to detect the arrival of a single file.
Summary
You are going to create a schedule with two jobs. One job will create the file we are looking for and the other will be the File Arrival job to 'look' for the new created file.
Instructions
Create the Schedule
- In Library > Administration, select on Master Schedule.
- Click the Add button.
- On the Master Schedule Definition screen:
- In the Name field, enter
File Arrival - Single File
- Add Documentation
- Pick your working days
- Configure Auto Build and Auto Delete.
- Click Save
- Click Back
Create the File Arrival Job
- Select the File Arrival - Single File schedule in Schedule List and click the View button.
- Select Add Job in the side menu
- On the Master Schedule Definition screen:
- In the Name field, enter
FA WindowsFile1
- In the Job Type drop-down, select Windows
- In the Machine Selectiondrop-down, select SMATraining
- In the User ID drop-down, select SMATRAINING\SMAUSER
- In the Job Action drop-down, select File Arrival
- In the File Name field, enter
"C:\Windows File Arrival\WindowsFile1.txt"
- In the Start Time drop-down, enter 0 day at
09:00 AM
- In the End Time drop-down, enter 0 day at
06:00 PM
- In the File Size Stable Duration (in secs) drop-down, enter
5
- Add Documentation to the Job.
- Give the Job a Frequency of Mon-Fri-N
- click Back
Create the File Creation Job
- Select Add Job.
- On the Master Job Definition screen:
- In the Name field, enter
Create File
- In the Job Type drop-down, select Windows
- In the Machine Selection drop-down, select SMATraining
- In the User ID drop-down, select SMATRAINING\SMAUSER
- In the Job Action drop-down, select Embedded Script
- In the Script drop-down, select Windows_File_Arrival
- In the Version drop-down, select LATEST (X)
- In the Runner drop-down, select PowerShell
- Click Save
- Add Documentation to the Job.
- Give the Job a Frequency of Mon-Fri-N
- Select the Frequency in the Active column, in the Job Build Status drop-down, select On Hold
- Click Save
- click Back
Build the Schedule
- Outside of OpCon verify that the folder:
C:\Windows File Arrival
DOES exist and is Empty. - Build the File Arrival - Single File Schedule Released for today.
- In Processes, view the Schedule and Job runs.
- Notice the Windows File Arrival Job is just running.
- Release the Create File Job in the File Arrival - Single File Schedule.
- Once the Job runs, verify that the file was created, and both Jobs Finished OK.