In this section: |
This topic provides step-by-step instructions on how to configure a basic inbound message flow for the iWay Integration Solution for UN/EDIFACT. The message flow represents the movement and tasks in the conversion of a message from Electronic Data Interchange (EDIFACT) format to XML format and acknowledgement of the message.
To access the iWay Service Manager Administration Console, you must first make sure that the iWay Service Manager service is running.
For instructions on starting iWay Service Manager, see the iWay Service Manager User's Guide.
or
from a browser such as Microsoft Internet Explorer, enter the following URL:
http://host:port
where:
The following image shows the URL with the default values.
Note: The default user name and password is iway.
The iWay Service Manager Administration Console opens, as shown in the following image.
The iWay e-Business Information Exchange (Ebix) framework supplies several Ebix files for the iWay Integration Solution for UN/EDIFACT.
An Ebix file for EDIFACT is named EDIFACT_transaction_set.ebx, where transaction_set is the transaction set number. For example, the Ebix file for EDIFACT transaction set D01B is named EDIFACT_D01B.ebx.
For details on the supported EDIFACT transaction sets, see EDIFACT Supported Versions.
This topic describes how to add an Ebix to the Registry on Windows and UNIX.
The Ebix pane opens, as shown in the following image.
You are prompted for the name of the Ebix and an optional description.
Note: This step must be repeated for each Ebix message set that is added to the Registry.
On the Ebix pane, you will see that the Ebix was successfully added. Later you will associate it with the channel for inbound processing.
Depending on your system configuration, there are two methods that you can use to add an Ebix to the Registry on UNIX.
In iWay Service Manager, a special register is a name-value pair that defines a variable that is carried throughout the system. Once defined, this variable is available to all components of the system. Within the EDIFACT components, a Best Practice is to use special registers to define inputs and outputs. When packages containing channels are migrated between systems, the only changes required to deploy in the new location is to modify these special registers and build the channel. Channels may have many locations and this practice will minimize the effort required to migrate. For a complete list of system special registers that are provided, see the iWay Service Manager Programmer's Guide. For more information on defining a special register of your own, see the iWay Service Manager User's Guide.
The sample inbound channel uses a set of special registers. For example:
To add a special register set to your channel:
The Channels pane opens.
The Assign register pane opens.
An inlet defines how a message enters a channel. It typically contains a:
Select File from the Type drop-down list and click Next.
The configuration parameters pane opens.
Parameter |
Value |
---|---|
Input Path * |
sreg(EDIFACT.Input) This value is a special register that uses a defined directory in which input messages are received. Make sure that you have created this directory; otherwise, errors will occur during deployment. |
Destination * |
sreg(EDIFACT.GoodOutput) This value is a special register that uses a defined directory in which output files are stored after transformation. Make sure that you have created this directory; otherwise, errors will occur during deployment. |
Removal Destination |
sreg(EDIFACT.Archive) This value is a special register that uses a defined directory to which input messages are moved if they fail during transformation. Make sure that you have created this directory; otherwise, errors will occur during deployment. It is recommended to configure a removal destination when you are constructing a basic channel. |
Suffix In |
* Input files with any file extension are allowed. |
Suffix Out |
xml The extension for output files is .xml. |
You are prompted for the name of the listener and an optional description.
The EDIFACTBatchSplitter internally splits EDIFACT input files into multiple individual EDIFACT transactions. The file will then be processed into one XML output when passed to the EDIFACT Preparser. You can also use the EDIFACTBatchSplitter if there is only one EDIFACT transaction.
For details on the supported EDIFACT transaction sets, see EDIFACT Supported Versions.
The Preparsers configuration parameters pane opens.
Disabled by default, the Timestamp option writes a timestamp to the log file. When enabled, the log file will display the start and end time of the file transformation and the input file name that is used. This feature is useful in development or debugging environments when processing batches of files. When the transaction log is not in use (for example, in a production mode) then this information is available in the Activity Log.
You are prompted for a name and optional description for the new preparser.
The EDIFACTPreparser is used with the EDIFACTBatchSplitter. It processes an EDIFACT input file which has been split by the BatchSplitter into multiple XML output files. One XML output file is produced for each EDIFACT transaction. EDIFACTPreparser should be used when there is only one EDIFACT transaction being processed.
For details on the supported EDIFACT transaction sets, see EDIFACT Supported Versions.
The Preparsers configuration parameters pane opens.
The Template field is used to locate the template in the Ebix, which is used during the transformation from EDIFACT format to XML format.
Disabled by default, the Timestamp option writes a timestamp to the log file. When enabled, the log file will display the start and end time of the file transformation and the input file name that is used. This feature is useful in development or debugging environments when processing batches of files. When the transaction log is not in use (for example, in a production mode) then this information is available in the Activity Log.
The InsertGroupLoop parameter inserts a group loop node in the generated XML document. By default, this parameter is set to true.
The preparser obtains the message type and version information from the EDIFACT input document. In the parameter, the character "%" represents the message type, and the character "^" represents the version.
For example, if the message type for the EDIFACT document is INVOIC and the version is D01B, the constructed template name is FACT_INVOIC_D01BtoXML.xch.
You are prompted for a name and optional description for the new preparser.
Now that you have added a File listener and splitter preparser to the Registry, you are ready to add and define an inlet. You will associate the previously created listener and preparser with the inlet.
Parameter |
Value |
---|---|
Name * |
EDIFACTtoXML_Inlet |
Description |
Inlet for EDIFACT to XML. |
The next pane prompts you to select a listener.
The listener is associated with the inlet. Now you need to associate the preparser created earlier with the inlet.
For this sample channel configuration, you will define a route that will invoke the EDIFACT to XML validation process flow. The outcome of the validation process flow will place valid XML data in a defined output folder. Invalid EDIFACT data will be routed to an errors folder. A validation report will also be sent to the appropriate folder.
This section describes how to create a validation process flow using iWay Designer and bind it to a sample outbound channel as a route.
To create a new project and start the process flow using iWay Designer:
The Designer Project Information dialog box opens, prompting you for a project name and optional description.
In the Description field, type a brief description (optional) to describe the project.
The Designer Project Bindings dialog box opens.
The iWay Process Configuration dialog box opens.
In the Description field, type a brief description (optional).
The new EDIFACTToXML node appears under the Processes folder, and the workspace displays a Start object.
You are ready to build the EDIFACTToXML validation process flow by configuring objects to it and specifying their relationships.
To configure objects for the process flow using iWay Designer:
The New Service Object dialog box opens.
The Service Type dialog box opens.
The Define Service dialog box opens.
The Properties dialog box opens.
The new Service object (XDEDIFACTAckAgent) appears in the workspace.
The Line Configuration dialog box opens.
This option indicates that there are no conditions that affect the path, and that the path between the two objects will always be followed.
A line appears between the objects to indicate that a relationship has been established.
The New File Object dialog box opens.
The Define File Type dialog box opens.
The Properties dialog box opens.
Sreg(EDIFACT.Ack)
Sreg(basename)__*.edifact
The new File object, File Output Acknowledgement, is added to the workspace area.
The Line Configuration dialog box opens.
A line appears between the objects to indicate that a relationship has been established.
The End Name and Description dialog box opens.
The End Name Schema dialog box opens.
The Properties dialog box opens.
The new End object appears in the workspace.
The Line Configuration dialog box opens.
A line appears between the objects to indicate that a relationship has been established.
The End Name and Description dialog box opens.
The End Name Schema dialog box opens.
The Properties dialog box opens.
The new End1 object appears in the workspace.
The Line Configuration dialog box opens.
A line appears between the objects to indicate that a relationship has been established.
The New Service Object dialog box opens.
The Service Type dialog box opens.
The Define Service dialog box opens.
The Validation Report object appears in the workspace.
The Line Configuration dialog box opens.
A line appears between the objects to indicate that a relationship has been established.
The New File Object dialog box opens.
The Define File Type dialog box opens.
The Properties dialog box opens.
sreg(EDIFACT.ValidRpt)
sreg(basename)_*.xml
The new File object, File Output Validation Report, is added to the workspace area.
The Line Configuration dialog box opens.
A line appears between the objects to indicate that a relationship has been established.
The Line Configuration dialog box opens.
Note: If you do not want to create APERAK or CONTROL, but need to monitor accept or reject rules validation status, a validation report can be substituted for the acknowledgement agent to update the SREG.
A line appears between the objects to indicate that a relationship has been established.
The New Test Object dialog box opens.
The Test Operands dialog box opens.
XPATH(/documents/ValidationReport/Report/Errors/error)
The Value Occurrences dialog box opens.
The new Decision Test object appears in the workspace.
The Line Configuration dialog box opens.
A line appears between the objects to indicate that a relationship has been established.
The Property Manager dialog box opens.
SREG1 appears in the Name column.
The Set Name and Description dialog box opens.
The Define Events dialog box opens.
The new Set object (Good Validation) appears in the workspace.
The Set Name and Description dialog box opens.
The Define Events dialog box opens.
The new Set object (Bad Validation) appears in the workspace.
The Line Configuration dialog box opens.
A line appears between the objects to indicate that a relationship has been established.
The Line Configuration dialog box opens.
A line appears between the objects to indicate that a relationship has been established.
The Line Configuration dialog box opens.
A line appears between the objects to indicate that a relationship has been established.
The Line Configuration dialog box opens.
A line appears between the objects to indicate that a relationship has been established.
The process flow is now complete.
Now you need to validate the process flow and publish it to the Registry of the iWay Service Manager Administration Console for use in the route of a channel for outbound processing.
Validating a process flow ensures that its structure is correct. Publishing a process flow makes it available in the Registry for use in a channel configuration. For instructions on validating and publishing the process flow, see the iWay Designer User's Guide.
Your next step is to add a new route to the Registry using the iWay Service Manager Administration Console and associate the process flow with it.
To define a route and associate the process flow with It:
Parameter |
Value |
---|---|
Name * |
EDIFACTToXML_Route |
Description |
This route will invoke the EDIFACT to XML process. The outcome of the process will place valid EDIFACT XML data in your Good File folder. Invalid EDIFACT XML data will be routed to your Bad File folder. |
You are prompted for the type of component to associate with the route.
The route, with its associated process flow, has been successfully defined.
An outlet defines how a message leaves a channel. An emitter is a transport protocol that sends a document to its recipient. In the sample configuration, we will use a File emitter. For details on supported protocols, see the iWay Service Manager Protocol Guide.
For the channel in this example, you will add two emitters to the Registry. Then you will define two outlets, associating one emitter with each outlet.
When you associate the outlets with the channel in later steps, you will apply a condition to each one to dynamically direct the flow of the output document based on its content.
In the example, you will add an emitter for the transformed EDIFACT input data. Two emitters will be defined. The purpose is to separate EDIFACT data that passes validation and those that failed. You will set a condition statement to ensure that the data is emitted to their corresponding folders. The condition settings will be as follows:
Good Output Emitter:
Cond(_sreg(Sreg1),EQ, 'G') and _isXML() and _Cond(_root(),ne,'documents')
This condition is checking the special register SREG1 for a value of 'G' (this was set in the process flow). It is also checking to see if the data is formatted in XML. The last statement is allowing only XML documents where the root tag is not equal to documents. An XML with a root tag of documents is the validation report. In this Emitter we are interested in the transformed XML document only.
Bad Output Emitter:
Cond(_sreg(Sreg1),EQ, 'B') and _isXML() and _Cond(_root(),ne,'documents')
This condition is checking the special register SREG1 for a value of 'B' (this was set in the process flow). It is also checking to see if the data is formatted in XML. The last statement is allowing only XML documents where the root tag is not equal to documents. An XML with a root tag of documents is the validation report. In this Emitter we are interested in the transformed XML document only.
This procedure describes how to configure an emitter for transformed EDIFACT input data that passes validation.
The configuration parameters pane opens.
Parameter |
Value |
---|---|
Destination * |
sreg(EDIFACT.GoodOutput)\sreg(basename)__*.xml This value is the directory where the transformed XML will be placed for any EDIFACT input data that has passed validation. sreg(EDIFACT.GoodOutput) is a special register value that uses a defined directory in which output files are stored after transformation. For more information, see Adding Special Register Sets. Make sure that you have created this directory; otherwise, errors will occur during deployment. On output, an asterisk (*) in the destination file name is replaced by a date and time stamp. For details on the special register (SREG) used in the preceding file name, see the iWay Service Manager User's Guide. |
Create Directory |
false |
Parameter |
Value |
---|---|
Name * |
Good_Output_Emitter |
Description |
Emitter for EDIFACT XML output that passes Report Validation. |
Parameter |
Value |
---|---|
Name * |
Good_Output_Outlet |
Description |
Good File Outlet for EDIFACT |
The next pane prompts you to select an emitter.
This procedure describes how to configure an emitter for transformed EDIFACT input data that fails validation.
The configuration parameters pane opens.
Parameter |
Value |
---|---|
Destination * |
sreg(EDIFACT.BadOutput)\sreg(basename)__*.xml This value is the directory where the transformed XML will be placed for any EDIFACT input data that has failed validation. sreg(EDIFACT.BadOutput) is a special register value that uses a defined directory in which output files are stored after transformation. For more information, see Adding Special Register Sets. Make sure that you have created this directory; otherwise, errors will occur during deployment. On output, an asterisk (*) in the destination file name is replaced by a date and time stamp. For details on the special register (SREG) used in the preceding file name, see the iWay Service Manager User's Guide. |
Create Directory |
false |
Parameter |
Value |
---|---|
Name * |
Bad_Output_Emitter |
Description |
Emitter for EDIFACT XML output that failed Report Validation. |
Parameter |
Value |
---|---|
Name * |
Bad_Output_Outlet |
Description |
Bad File Outlet for EDIFACT |
The next pane prompts you to select an emitter.
This section describes how to define a channel.
Parameter |
Value |
---|---|
Name * |
EDIFACTtoXML_Channel |
Description |
Channel for EDIFACT to XML inbound processing. |
You are prompted to associate components with the channel.
The inlet is added to the channel. Now you need to associate the route defined earlier with the channel.
The next pane prompts you for the component type.
On the next pane, you are prompted to select a route.
The Set Condition pane opens.
COND(_sreg(SREG1), EQ, 'G') and _isXML() and _COND(_root(),ne,'documents')
The Set Condition pane opens.
COND(_sreg(SREG1), EQ, 'B') and _isXML() and _COND(_root(),ne,'documents')
The Channel Definitions pane opens.
Now that you have associated all the components with the channel, you are ready to build it.
The Channel Definitions pane opens.
For more information on creating register sets, see Adding Special Register Sets.
Now that you have associated all the components with the channel you are ready to build it.
The results of the build are displayed on the right pane.
If an error or errors are displayed in the Message column, take the appropriate action as instructed.
Deployment is the mechanism by which a channel moves from being stored in the Registry to becoming active in iWay Service Manager. For more information on deployment, see the iWay Service Manager User's Guide.
The Channel Management pane reopens.
The red X under Status changes to a green check mark to indicate that the channel has been started. If an error or errors are displayed, take the appropriate action as instructed.
Using the Archive Manager feature of iWay Service Manager, you can archive your channel configuration with its associated components and import them into another Registry. They will then be available from that Registry for modification or reuse.
For details on this feature, see the iWay Service Manager User's Guide.
iWay Software |