A File Command Line step is defined for a File System Connection and defines a command to be executed by the Agentry Server on the host system of the Server. This command is contained in a script file, with a default file extension of .bat, which is the Windows batch file extension. This extension may be changed to match the script language used in the file. The command executed by the Agentry Server can be monitored for its return value. The script file is processed by the Server to expand any SDML tags it may contain prior to execution against the host system.
The contents of the script file for this step type may be accessed directly on the Agentry Development Server for the application project. The file path listed for this file is relative to the installation location of this Server. If this file is modified it is not necessary to publish the application project for the change to be exhibited. In a production environment this file is not directly accessible in this manner and must be modified through the Agentry Editor. Changes made in a production environment must be published.
As an alternative to storing the command in an external file, it may be contained in the Command attribute of the step. Such a command must consist of a single line. By default the Command attribute is set to the SDML tag <<script>>, which expands at run time to the file referenced in the steps File attribute.
A file command step can be defined to wait for the command it calls to complete execution. When defined in this manner, the back end synchronization for a user will not continue until the command returns, or until the defined wait period expires. If the wait period is exceeded, the Agentry Server will log an error and the synchronization will be halted.
If the step is not defined to way for the command to complete, an error will only be logged if the defined command cannot be executed by the Server for any reason.
The script file or the text in the Command attribute for this step is processed by the Agentry Server, which runs it through the Server’s SDML pre-processor before executing the step. The results of this SDML expansion are written to a temporary directory, based on the Server’s configuration.
ServerDirectory\Application\Development\Scripts
where ServerDirectory is the installation location of the Agentry Development Server.