Scheduling and the Timeout Parameter

<< Click to Display Table of Contents >>

Navigation:  Robo-FTP User's Guide > Robo-FTP Framework > Job Definitions >

Scheduling and the Timeout Parameter

 

Framework jobs work by defining a file set. Each step operates on the files in the set before moving on to the next step (sometimes adding/removing files in the set depending on what the step is doing). This methodology enables the Framework to provide a high degree of reliability and accountability, but may require you to adjust the way you think about certain business processes.

 

For example, consider a common scenario where the business requirement is to download files from a server as they appear. If you are used to old-fashioned procedural scripts, your first thought might be to craft a job that is scheduled to run every five minutes that uses a PULL step to check for the existence of files and times out after a minute or so if there are no files to download.

 

You can set up a job this way with the Framework, but this will result in cluttering the Framework interface (and your inbox) with error notifications every time the job runs when there are no files available at that moment to download.

 

A better approach is to consider the question, "what is the longest the system should go without finding any files to download before considering it to be an error?" For example, let’s say that you decide it is not a problem if there are no files to download after only waiting a few minutes, but you DO want to be notified if 24 hours go by without downloading any new files.

 

In this case, the best way to set up the job is to schedule it to run every five minutes as before, but to set the timeout value for the PULL step to 1440 (1440 minutes = 24 hours). The scheduler will see that the job is still running and will not launch another instance of that job until the currently running instance completes.

 

You can use the same approach for handling processes that are watching for files on your local system. In those cases, you use a MONITOR step to watch for files instead of a PULL step.