The File Trigger Properties window defines the circumstances under which the job will be triggered.
Optional Descriptive Name
Optionally, provide a descriptive name for this trigger. Otherwise, a description will be created automatically based on the file names you specify.
Enable this Trigger
If this box is checked, the trigger is enabled and will cause the job to run. If this box is not checked, adTempus will ignore this trigger.
Trigger Conditions
Select the conditions under which the job will be executed. You must select at least one option.
Files
Specify the files or directories to watch. You may specify a single file (e.g., "c:\data\jobtrigger.txt") or use wildcards (e.g., "c:\datafiles\newfiles\*.dat").
You may specify as many file specifications as you wish. The job will be triggered when a file is found that matches any of the file specifications you have provided and matches all the other conditions you have specified.
Minimum Time Between Triggers
Specify the minimum time (in seconds) that must elapse after this trigger fires before adTempus will fire it again.
adTempus evaluates the files approximately every 10 seconds; specify a longer time if appropriate.
You should use this option and/or the options available on the job to prevent duplicate instances to prevent your job from being triggered continually. For example, suppose you are monitoring a log file for changes. The first time adTempus detects a change to the file, it will trigger your job. If the application that is writing to the log file continues to write to it, adTempus will continue to trigger your job each time it detects a change (it will check for changes roughly every 10 seconds). |
Wait for exclusive access to the file
If this option is checked, adTempus will not trigger the job until it can get exclusive access to the file (i.e., no other application is reading or writing the file).
Capture the file
If this option is checked, adTempus will capture the file that satisfied the trigger and save it in the job history.
Selection Script
You may specify a script that is to be run to determine whether a file should cause the job to trigger. When you specify a script, adTempus evaluates files as follows:
It finds all files that match your file specifications.
It discards any files that do not meet other selection criteria you have specified.
For each remaining file, it calls the script you specify. Information about the file to be tested is passed to your script in the Parameters object.
Your script evaluates the file in whatever way is appropriate. If the job should be triggered based on the file, your script sets the global Result variable to True, and adTempus triggers the job when your script returns. Otherwise, your script sets the Result variable to False, and adTempus continues to the next file.
Description/Notes
Enter any extended descriptive information or notes for this trigger. There is no limit on the length of the text.