FTP facility

Introduction

Originally CumuluUtils was designed just to create the output and let the user decide what to do with it. As the system grew and the number of output files grew with it that became a bit awkward and slow so automation of that process was required. As CumulusUtils is designed for a remote website and the output is intended to be used for that website, it was logical to copy the output files directly to that URL.

Operation

The operation is implicit and has no specific commandline or module name. When CumulusUtils is run, with whatever command, the output is copied directly to the specified URL when the application is required to do so. All protocols supported by CumulusMX are also supported by CumulusUtils that is: FTP, FTPS and SFTP. See also PHP Uploads.

The FTP upload operation is subject to the optimisation parameter Thrifty, see also the commandline. The Thrifty command qualifier finds its origin in the presence of low debit payed lines over which the output has to be transferred. This called for reduction of the output size. For details see Thrifty.

Output

If configured, there can be a specific FTP logfile which logs more information on the transfer process than the standard logfile. That logfile goes to the utils/utilslog directory and will have a name of: yyMMddHHmmFTPlog.txt so every run will have its own logfile.

Inifile parameters

   [FTP site]
   DoUploadFTP=true | false                          (when false no Uploads take place, when true it is otherwise)
   UploadDir=                                        (specification of the FTP directory where to upload the output files without trailing slash)
                                                     (When empty the CumulusMX inifile specification for the destination is used)
   FtpLog=on | off                                   (If on the additional FTP logging is done, when off otherwise)

Inner working

If DoUploadFTP equals true, then the FTP username and password the other parameters for the FTP site are taken from the Cumulus.ini file will be used to upload the output files. So beside the username and password the Host, Port number, Directory, ActiveFTP, Sslftp are used. All other parameters are ignored. The UTF8encode setting is irrelevant because CumulusUtils uses UTF8 for all its files so can't be optional.

If the required Host inifile parameter is empty, then no upload takes place. If the destination in CumulusUtils is NOT specified (UploadDir is empty) then the destination specified in Cumulus.ini is used (Directory).

Then next, in a loop over all output files entitled , the upload takes place as the final stage of the CumulusUtils run.