Using the XML File Feed (WinRetail Integration)

Purpose: Use the XMLFILE job in Working with Integration Layer Processes (IJCT) to process batches of XML messages. The job checks a designated folder on your server to process the:

• CWOrderIn message: see the Generic Order Interface (Order API)

• inCreateInvXaction message: see the Generic Inventory Transaction Upload

• CWReceiptIn message: see the Purchase Order Receipt In API

XML File Feed Process

XMLFILE job: When the XMLFILE job in Working with Integration Layer Processes (IJCT) starts, it checks the folder designated in the IJCT_XMLFILE_DIRECTORY_PATH setting in the cwdirectcp_interfaces.properties file. See WinRetail Properties File Settings for setup information.

XML files in the designated folder: The job looks for a file that ends with the .xml suffix and starts with:

InvTran_ for the inCreateInvXaction message

Order_ for the CWOrderIn message

PORcpt_ for the CWReceiptIn message

XML file contents: Each of the .xml files should contain a series of valid XML messages, each separated by a carriage return.

About the file names:

• The file name is not case-sensitive.

• Each file name should be unique. Typically, you would use a time or date stamp to identify each file (for example, InvTran_113010.xml).

The XMLFILE job submits the file to the related API.

Example: The folder contains a file named Order_113010.xml. The XMLFILE job submits the messages in the file to the generic order API for processing.

Starting integration layer processes? It is not necessary to start the XMLFILE job in order to process the messages in the designated folder.

Response file? If the messages in a file require a response or generate any errors, the job creates a text file that ends with the .rsp suffix, and puts the file in the designated folder. This file contains the responses, errors, or both.

Example: If any of the messages in the Order_102710.xml file have a response_type of D or E or generate an error response, the job creates a file named Order_102710.rsp containing the responses or errors.

Processed file: After processing each file, the job renames it using the .prcd suffix and leaves it in the designated folder.

Example: After processing the Order_102710.xml file, the job renames it Order_102710.prcd.

How often to check the folder? The job uses the Outbound delay time specified for the XMLFILE job at the Integration Layer Process Screen (Change Mode) to determine how many seconds to wait before checking the designated folder for unprocessed files. The default is 60 seconds, but you can override this default.

Starting and stopping the XMLFILE job: In addition to using the Start and End options at the Work with Integration Layer Process Queues Screen, you can use periodic functions to start and stop the XMLFILE job. See WinRetail: Periodic Functions for more information.

Note: To stop the job, you can also put a file named stop.xml in the designated folder. Since the job processes the files in alphabetical order, it processes this file last and shuts down if this file is in the folder along with the files whose names begin with InvTran_, Order_, and PORcpt_.

Troubleshooting: If the IJCT_XMLFILE_DIRECTORY_PATH setting in the cwdirectcp_interfaces.properties file does not specify a valid path:

Starting the XMLFILE job interactively: The Work with Integration Layer Process Queues Screen displays an error when you start the job:

IJCT_XMLFILE_DIRECTORY_PATH is invalid.

Starting or stopping the XMLFILE job through a periodic function: A message such as the following is written to the CWSerenade Application Log:

IJCT XMLFILE job not started because IJCT_XMLFILE_DIRECTORY_PATH not set up for the server where the start was run.

For more information: See WinRetail Integration Overview for background information on the integration.

SO16_04 Serenade 5.0 March 2015