During run time, the FTP Poll Directory activity connects to an FTP Server and polls for the existence of the specified file or files at the specified location. After reading the contents of the file or files and mapping the contents into variable or variables of the orchestration, the FTP Poll Directory activity may delete the file or files, move the file or files, or leave the file or files in the directory of the FTP Server.
The FTP Poll Directory activity is a starter activity. When an orchestration that starts with an FTP Poll Directory activity is deployed to the Integration Appliance, the Integration Appliance polls for file or files to be added to a specific directory on the FTP Server. When a file or files is shown on the FTP Server, an orchestration job is started to processes the file or files and the rest of the activities in the orchestration. For more information, see Polling Interval Behavior. For an example of an orchestration using the FTP Poll Directory activity, see the Getting Started Guide.
Symbolic Links to... | Hard Symbolic Links | Soft Symbolic Links | Notes® |
---|---|---|---|
Files | Not Supported | Not Supported | The FTP Poll Directory activity does not interpret symbolic links to files as files and therefore symbolic links to files are not processed by the FTP Poll Directory activity during run time. |
Directories | Supported | Supported |
You might want to enable persistence for an orchestration that contains an FTP Poll Directory activity. For example, if you disable persistence and have an orchestration job with an FTP Poll Directory activity with the Keep in place option selected, during run time if a failure occurs that causes the job to stop, when the orchestration is restarted it processes the file again. The state of the job is lost and Integration Appliance does not know that it has already processed the file. For more information, see Enabling persistence.
Field | Description |
---|---|
File Named | Specifies a pattern or regular expression that
defines the filename or filenames to get from the FTP Server. The
processing of the regular expression is done by the FTP Server. For
more information, see the FTP Server documentation on regular expressions
. Typically, FTP Servers support the following wildcards in their
regular expressions:
Note: Because the processing of the regular expression is done
on the FTP Server, the case sensitivity is determined by FTP Server.
If the FTP Server is case sensitive, the file matching done by the
FTP Poll Directory activity is also case sensitive.
|
In Directory | Specifies the directory where the Integration
Appliance looks for files on the FTP Server. You can specify a directory
using one of the following options:
Note: UNIX: If you
specify a relative directory path when connecting to an FTP Server
on a UNIX machine, verify that
the FTP home directory has been correctly specified in the /etc/password
file for the user account connecting to the FTP Server.
|
Test | After a regular expression has been specified in the File Named field and the directory to look for files on the FTP Server has been specified in the In Directory field, click Test to test the regular expression against the set of files in the specified directory on the FTP Server. A dialog box will appear listing any matching files. |
Of Type | Specifies how to read in the contents of the
file - either as binary data or encoded text. If the Text option
is selected, set the encoding type using one of the following options:
Note: Some double-byte characters are not converted using the
SHIFT-JIS encoding. For more information, see Using the Shift-JIS encoding.
|
CAUTION: You must specify the Transfer
as Text (ASCII) option for FTP activities when retrieving text files
and placing text files on an FTP Server for Endpoints that manipulate
text data while transferring data from/to the FTP endpoint in ASCII
mode. For example, mainframe and DOS FTP Endpoints manipulate ASCII
data when passing data in ASCII mode. For example, if your orchestration
retrieves ASCII files using the FTP Poll Directory activity and places
ASCII files using the FTP Put File activity to a mainframe FTP Server,
you must specify the options in the following tasks in Studio:
|
|
After reading the file | Delete it - Delete the file after the file has been read. Move to directory - Move the file to the specified directory after the file has been read. Specify
the directory that the file is moved to during run time, using one
of the following options:
|
Attention: Specify the directory
separator after the last listed directory name. For example, to move
a file to the processed/acme directory in a relative path, specify
the following directory in the Move to directory field: processed/acme/
Optional
- Specify the format of the file name after it has been renamed. From
the Pattern drop-down list, select the desired
pattern. To specify the character used to separate the sub-fields
in the file name, enter a character in the Pattern Separator field.
Specify the run time behavior when a file with the same file name
exists:
Note: The first time the FTP Poll Directory activity polls
during run time, if the activity is unable to move the file because
the specified move to directory does not exist, a warning is logged
(not an error) to the Web Management Console (WMC) and the file stays
in place. For all subsequent polls, the activity does not attempt
to move the same file and an info level message is logged to the WMC
stating that the file has already been processed.
Keep in place - Leave the file in the input directory after the file has been read. |
|
Advanced Options | Description |
Duplicate List Size | Size of the internal list used by the Integration Appliance to keep track of which files on the FTP Server have been polled or not. The default value is 10000. You should only specify a size larger than the default. |
Field | Description |
---|---|
Retry | |
1) Wait __ second(s) between each retry. | The number of seconds that the Integration Appliance waits before trying to establish a connection to the FTP Server. |
2) Try to connect __ times before failing. | Specifies the retry count - the maximum number
of times the Integration Appliance attempts to establish a connection
to the FTP Server before issuing an error. If an orchestration that
starts with an FTP Poll Directory activity is deployed and
the Integration Appliance cannot connect to the specified FTP Server,
the Integration Appliance logs the connection errors as warnings in
the system log until the retry count value is reached. When the retry
count is reached, the Integration Appliance logs an error in the system
log, resets the connection error count to zero, and continues to attempt
to establish a connection to the FTP Server. For example, you set the retry count to 3. The first, second, and third connection errors appear in the system log as warnings. The Integration Appliance logs the fourth connection error as an error and resets the connection error count to zero. Therefore, the fifth connection error generates a warning in the system log. The Integration Appliance continues to attempt to establish a connection to the FTP Server. |
Output Parameter | Description |
---|---|
filename | Provides the name of the file found on the FTP Server. |
data | Provides the contents of the file. |
timestamp | Provides the date and time as a string in the
XML Schema dataType format (YYYY-MM-DDhh:mm:ss, where YY is the year,
MM is the month, DD is the day, hh is the timezone, mm is the minutes,
and ss is the seconds.) Note: If the timestamp output
parameter is mapped in the Map Outputs task but the MDTM (return
the modification time of a file) functionality is not available or
is not enabled for the FTP Server, during run time the orchestration
will stop processing due to this error. A warning is generated and
the Epoch date (1/1/1970) is returned in the timestamp output
parameter.
|