Show TOC

Configuring the Sender File AdapterLocate this document in the navigation structure

Use

You create a sender file adapter if you want to send file content from a file system to the Integration Server or the PCK. This only applies to files that are not read-only.

Prerequisites
  • There can be exactly one sender agreement for the defined communication channel.
  • If you are developing a module for the adapter and want to access the file name in the module, see SAP Note 819761.
Procedure
...
  1. The Transport Protocol is File System (NFS).
  2. To send the file content to the Integration Engine or the PCK unchanged, select
    File
    under Message Protocol.
    If you want to send the Integration Engine or the PCK a text file with complex data structures that are to be converted to an XML document, select
    File Content Conversion
    and make the required entries for conversion under Content Conversion Parameters (see below).
  3. Select the Adapter Engine on the Integration Server, or select a non-centrally installed Adapter Engine.

    This selection is not available in the PCK.

Define File Access Parameters
  1. Select the Source tab page.
  2. Specify the Source Directory containing the files to be processed.

    You can either specify the entire name or a name relative to the working directory of the Adapter Engine. On all platforms (including Windows), use a forward slash (/) to separate directory names in accordance with the Java specification.

  3. Specify the File Name of the file to be processed.

    If you want to specify multiple files, you can use placeholders in the file name and enter file name masks. Use exclusion masks to exclude particular files from the selection. Files are always processed in ascending alphabetical order.

    More information: Defining Placeholders, File Name Masks, and Exclusion Masks

  4. If you want to transfer additional files to be included in the XI message as attachments, select Additional File(s).

    More information: Specifying Additional Files in the Sender File Adapter

Define Processing Parameters
  1. Select theProcessing tab page.
  2. Under Quality of Service, specify how a message is to be processed by the Integration Engine/PCK.

    For Quality of Service Exactly Once In Order, enter the Queue Name.

    More information: Quality of Service

  3. Specify the following for the poll interval:
    • Poll Interval (secs): Number of seconds that the adapter must wait if no files are found for processing.
    • Poll Interval (msecs) Number of milliseconds that the adapter must wait if no files are found for processing

      If you set Poll Interval (secs) to null, processing times will be short and close to real time.

      If you set Poll Interval (secs) and Poll Interval (msecs) to null, the adapter is called once.

    • Retry Interval (secs): Number of seconds that the adapter is to wait before a file processed with errors is processed again

      If the value is set to null, then the adapter is canceled if an error occurs, even if a value greater than null is specified for Poll Interval (secs).

      If you do not enter a value, the value from Poll Interval (secs) is used.

  4. Under Processing Mode, specify what is to happen to files that have been processed successfully.
    • Archive
      • To add a time stamp to the file name, select Add Time Stamp.

        The time stamp has the format yyyMMdd-hhMMss-SSS. The time stamp ensures that the archived files are not overwritten and it enables you to sort them according to the time that they were received.

      • Enter the name of the Archive Directory.
    • Delete
    • Test

      Files are not processed.

      Only use this mode to test the configurations of the file/FTP adapter or the Integration Engine/PCK. It is not suitable for productive operation.

    • Set to Read-Only

      Successfully processed files are given this attribute. Only writable files are processed.

  5. Under Handling of Empty Files, specify how empty files (length 0 bytes) are to be handled:
    • Do Not Create Message

      No XI messages are created from empty files.

      The files are processed according to the selected processing mode.

      For example, if the processing mode is Delete, empty files are deleted in the source directory.

    • Process Empty Files

      XI messages are created with an empty main payload.

      The files are processed according to the selected processing mode.

    • Skip Empty Files

      No XI messages are created from empty files.

      Empty files are skipped and remain in the source directory.

  6. To archive source files where a permanent error occurred during processing, select Archive Source Files with Errors.

    A permanent error occurs either during the conversion of the file content, or in a module in the module processor.

    More information: Adding MessageTransformBean in the Module Processor

    • Specify the Error Archive Directory.
    • To add a time stamp to the archived file, select Add Time Stamp.
  7. If you also want to transfer files that are locked by other applications, select Process Read-Only Files.

    Only set this indicator if you are sure that no data will be lost. If you have selected Set to Read-Only as the Processing Mode, this indicator is not available.

  8. If you used placeholders when specifying the file name, define the Processing Sequence of the files:
    • If you select By Name, files are processed in alphabetical order by file name.
    • If you selectBy Date, files are processed according to their time stamp in the file system, starting with the oldest file.
  9. Specify the File Type of the document as Binary or Text.
    Caution

    XML text documents usually contain their own code page description. Set the File Type to Binary.

    If you have selected Text, specify a code page under File Encoding. The default setting is to use the system code page that is specific to the configuration of the installed operating system. The file content is converted to the UTF-8 code page before it is sent.

    Permitted values for the code page are the existing Charsets of the Java runtime. According to the SUN specification for the Java runtime, at least the following standard character sets must be supported:

    • US-ASCII

      Seven-bit ASCII, also known as ISO646-US, or Basic Latin block of the Unicode character set

    • ISO -8859-1

      ISO character set for Western European languages (Latin Alphabet No. 1), also known as ISO-LATIN-1

    • UTF-8
    • UTF-16BE

      16-bit Unicode character format, big-endian byte order

    • UTF-16LE

      16-bit Unicode character format, little-endian byte order

    • UTF-16, byte order
      Note

      Check which other character sets are supported in the documentation for your Java runtime implementation.

Define Operating System Commands
  1. Specify the operating system commands that are to be executed before or after message processing.

    More information: Defining Operating System Commands Before/After Message Processing

Define Duplicate Handling Settings

  1. If you want to control the processing of the duplicate messages, select Enable Duplicate Handling, and then perform the following steps:
    1. Enter a value in the Duplicate Message Alert Threshold textbox.

System notifies the user with an alert message (warning) at the first occurrence of the duplicate message and stops processing these messages. In addition, it notifies the user with an alert message (error) with the n+1 duplicate message occurrence.

  1. If you want to disable the channel after the duplicate threshold is exceeded, select Disable Channel If Threshold Exceeded.
  2. The duplicate message is identified by the last modified time stamp of the file.
  3. This feature increases the robustness by avoiding the processing of  duplicate messages. It also provides flexible threshold configuration and channel deactivation (if threshold exceeds) options.
Define Content Conversion Parameters
  1. Select the Content Conversion tab page.
  2. If you have selected File Content Conversion as the Message Protocol, you can convert a text file with complex structures to an XML source format.

    More information: Converting Structures to XML Using the Sender File/FTP Adapter

Define Adapter-Specific Message Attributes
  1. Choose the Advanced tab.
  2. To save adapter attributes in the message header of the XI message, select Set Adapter-Specific Message Attributes.

    To apply the following attributes in the XI message header, set the corresponding indicators:

    • File Name (technical name: FileName)
    • Directory (technical name: Directory)
    • File Type (technical name: FileType)
    • File Encoding(technical name: FileEncoding)
      You can only set this indicator if you have specified the File Type as
      Text
      , and if the indicator for the message attribute File Type above is already set.
    • Source File Size(technical name: SourceFileSize)
    • Source File Time Stamp(technical name: SourceFileTimeStamp)

    The attribute namespace for the adapter is http://sap.com/xi/XI/System/File .

Define the Adapter Status
  1. Set the adapter to Active to enable messages to be exchanged.
Define Additional Parameters

To specify additional parameters for the adapter configuration, select Advanced Mode.

  1. File splitting (EOIO processing of large binary files)

    You can select this settings for sending larger files (for example, larger than 1 gigabyte). The file is first divided up into smaller file parts. These file parts are then processed individually at runtime.

    You can configure the size of the file parts (in megabytes).

    Note

    If you select this option hen you cannot execute a mapping or any other content conversion.

    Caution

    To be able to activate this function, the Quality of Service must be set to EOIO (on the Processing tab page).

    This function only works correctly for service interfaces with XI 3.0 compatible interface pattern.

  2. Msecs to Wait Before Modification Check

    Enter the number of milliseconds that the adapter must wait before it checks whether the files have been changed.

    This parameter is not available if you have selected File Content Conversion as the Message Protocol and then made an entry under Recordsets per Message to split an input file into several messages.

    Note

    This parameter is applicable only for the File adapter. If you enter a value in this field when configuring the sender FTP adapter, it will have no effect.

  3. Specify the maximum file size in bytes.

    The adapter only processes files that are smaller than the specified size. An error occurs if files are any larger.

  4. Specify the additional parameter names and parameter values in the table.
    Note

    Additional parameters are published in SAP Note 801926.