Fileset FTP protocol: Fileset Options tab

Inbound pane

This tables shows inbound configuration parameters:
Parameters Description
Directory Specify the inbound file directory path. You can also specify multiple directories. See Scanning multiple directories for inbound pickup.
Style Click the arrow to select from the list how messages are stored within the files. This determines how the driver processes each file.
  • If single, then the driver reads the contents of the file into a single message.
  • hl7 and nl specify different schemes for delimiting messages within the file.

    For nl style, the delimiter is <NL> between messages. As each message ends with <CR>, between messages would look similar to <CR><NL>.

    For example:
    MSH|……<CR><NL>MSH|……<CR><NL>MSH|……<CR><NL>

    File read/writes in nl mode do not support the Unicode UTF-16 encoding. The nl mode cannot be performed without knowing the encoding beforehand, which is not known.

    For hl7, the delimiter is <CR>MSH and the last character at end-of-file must be NL. The NL at the end-of-file indicates that it is the end of the message. Basically, each message ends with <CR>. With the hl7 style there must be <CR>MSH in-between each message. The MSH is technically not a delimiter because it belongs to the next message. It serves only as the indicator for the beginning of the next message during parsing. There are no delimiters between HL7 messages, as the engine seeks the <CR>MSH to find the beginning of the next message.

    For example:

    MSH|……<CR>MSH|……<CR>MSH|……<CR><NL>
  • len10 specifies a 10-byte record length, also called a length-encoded message.
  • eof specifies that the message has an end-of-file character, usually supplied by the computer’s operating system.
CRNL Convert This creates any file on a Windows server as a Windows-type file and not UNIX-type. CRNL is for Windows and NL is for UNIX. This option is first performed on each message (record) in a file. After this, the message delimited Style is performed.

CRNL to NL converts Windows-based files to UNIX-based files. NL to CRNL converts UNIX-based files to Windows-based files.

TPS pane

This tables shows TPS configuration parameters:
Parameters Description
Directory Parse Use this TPS to select programmatically which files to process on each Scan Interval, and in what order. Click Edit to open the TPS Editor. Edit TPS Proc Properties in this dialog box.
Note: Without a directory parse procedure on the inbound thread, the engine assumes that every file in the directory is to be processed.
Deletion Click Edit to open the TPS Editor. This dialog box is used to select the TPS through which the driver passes the processed file names.

Scheduling pane

This tables shows scheduling configuration parameters:
Parameters Description
Read Interval Specify the minimum time, in seconds, to wait between reading from a file.

This tells the driver to process a message every <n> seconds as long as there is work to do (for example, there are input files available).

In general, the read interval is fairly low so that the driver rapidly processes inbound messages.

Max Messages Specify the maximum number of messages to read from the file on each Read Interval.
Scan Interval Specify the minimum time, in seconds, between inbound directory scans for most message files.

This is the (minimum) number of seconds between inbound directory scans to look for new work.

This option is disabled if Use advanced scheduling is selected.

For example, the Scan Interval is 6000 (10 minutes), the Read Interval is 10, and Max Messages is 30. The directory is scanned every 10 minutes for files. If files are found after a scan, then the first file is read every 10 seconds. 30 messages are retrieved every read until the file is exhausted. The next file in the list of files that is retrieved by the scan is read every 10 seconds with 30 messages every read, and so on. This is carried out until all the files from the current scan are read.

Scan Mode

For scheduling, there are two scanning options:

  • Serial

    This option scans and picks the files in one of the IB directories in each interval.

  • Parallel

    This option scans all of the IB directories and then picks all of the files in each interval.

The scan order is the same as the directories order that is configured by the user.

The default mode is serial mode. This mode is backwards compatible.

Example:

The directory list is: one, two, three, four.

Only directory four contains a file.

Read Interval is 5.

Scan Interval is 20.

In Serial mode, four scan cycles are completed to get to that file, for a total of 80 seconds.

In Parallel mode, it takes 20 seconds.

Use advanced scheduling Select this to schedule recurring events, such as cycling log or SMAT files. Then click Setup to open the Scheduling dialog box.

Outbound pane

This tables shows outbound configuration parameters:
Parameters Description
Directory Specify the local directory path. This specifies the directory for local file delivery.
File Name Template Fileset FTP stores the file name for IB files, and after routing to an outbound Fileset FTP, it uses the inbound file name by default. With this option, you can define the template for outbound file names.

For example, if the template is SYS.TIMESTAMP, the outbound file name is similar to 20160411.

In another example, an outbound file name of site_testsite_p_5120.dat has a template of site_%CIS.SITE%_p_%MSG.PRIORITY%.dat.

If this field is left blank, then it reverts to the old behavior.

If this directory is specified, then File and File Name Template cannot both be empty.

For the templates, see Fileset FTP/Local outbound file name templates.

File Specify the default outbound file name.
Temporary File Specify the path and name of the temporary file to use when transferring data. If this text box is empty, then no temporary file is used. When the transfer is successfully completed, the temporary file is renamed to the value of the FTPTEMPFILE key. If this key is empty, then the file is uploaded as the actual file name.
Style Click the arrow to select from the list how messages are stored within the files. This value is particularly important when numerous messages are written to a file.
  • If single, then the driver reads the contents of the file into a single message.
  • hl7 and nl specify different schemes for delimiting messages within the file.

    For nl style, the delimiter is <NL> between messages. As each message ends with <CR>, between messages would look similar to <CR><NL>.

    For example:

    MSH|……<CR><NL>MSH|……<CR><NL>MSH|……<CR><NL>

    File reads/writes in nl mode do not support the Unicode UTF-16 encoding. The nl mode cannot be performed without knowing the encoding beforehand, which is not known.

    For hl7, the delimiter is <CR>MSH and the last character at end-of-file must be NL. The NL at the end-of-file indicates that it is the end of the message. Each message ends with <CR>. With the hl7 style there must be <CR>MSH in-between each message. The MSH is technically not a delimiter because it belongs to the next message. It serves only as the indicator for the beginning of the next message during parsing. There are no delimiters between HL7 messages, as the engine seeks the <CR>MSH to find the beginning of the next message.

    For example:

    MSH|……<CR>MSH|……<CR>MSH|……<CR><NL>
  • len10 specifies a 10-byte record length, also called a length-encoded message.
  • eof specifies that the message has an end-of-file character, usually supplied by the computer’s operating system.
Append data Click this to append data to the file, if it exists. Otherwise, the file is overwritten each time the thread starts up.

Override all of these outbound control values with a message’s DRIVERCTL metadata string.

Start-Up Procedures pane

Click Edit to open the TPS Editor. Use this dialog box to select the procedures to run when the thread starts. This is a TPS (Tcl Procedure Stream). Use it to trade messages with the remote end.