Sun ONE logo      Previous      Contents      Index      Next     

Sun ONE Integration Server B2B 3.6.2 Update 1, ECXpert Support for AS2 Messaging

Chapter 2
Example: End-to-End Test for AS2 Messaging

This chapter provides a detailed example that shows how to set up ECXpert inbound and outbound hosts for AS2 messaging and steps through a procedure to send and receive an AS2 message. If you need more information to configure the trading relationship using ECXpert, refer to the ECXpert documentation set at docs.sun.com.

If you plan to follow the procedure in this chapter to test your AS2 setup, AS2 must be installed on two ECXpert machines—one to act as the outbound host or sender, the other to act as the inbound host or receiver. Chapter 1, "Getting Started with AS2 Messaging: Installation and Configuration" gives the instructions for setting up the AS2 plug-in.


Example Overview

This example uses two members called partyA and partyB, which reside on the outbound host and the inbound host respectively. The purpose of the test is to ensure that you can send a plain messages end to end.


Setting up the Outbound Host

This section shows how to set up a partnership so that the outbound host can send AS2 messages. It contains procedures for the following tasks:

Perform these procedures using the ECXpert installation on the machine you are using for the sender.

    To create memberships
  1. Open the Support interface to ECXpert, and select Membership.
  2. Select Add and specify the fields in Table 2-1, as shown in Figure 2-1:
  3. Table 2-1  Field Values for Creating a Membership

    Field

    Value

    Member ID

    partyA

    Select

    Member is active

    Member is trusted

    Password

    If you do not specify a password, you must select the Member is trusted box.

    Figure 2-1  Add a Member Screen
    Screen capture of the Add a member activity.

  4. Select Next twice, bypassing the Contact Information page. These fields are not important for this test.
  5. Specify information for the Trading Address as shown in the following table and Figure 2-2.
  6. Table 2-2  Field Values for PartyA Address

    Field

    Value

    Address Type

    EDI

    Qualifier

    AS2

    Address

    PartyA

    Figure 2-2  Trading Address Screen
    Screen capture of the Add New Trading Address activity.

  7. Click Change to modify the member with the new trading address. This results in the address being added to the Existing Trading Address list, as shown in Figure 2-3.
  8. Figure 2-3  Trading Address Added Screen
    Screen capture of the Trading address added indicator.

  9. Repeat Step 1 through Step 5 to add the Receiver member, with the following differences:
    1. In Membership Information, specify partyB for the Member ID.
    2. In Trading Addresses, specify the following:
    3. Table 2-3  Field Values for ParyB Address

      Field

      Value

      Address Type

      EDI

      Qualifier

      AS2

      Address

      PartyB

    To create a service list
  1. From the Support interface, select Services.
  2. Select Add and specify the following field values, as shown in Figure 2-4:
  3. Table 2-4  Field Values for Creating a Service List

    Field

    Value

    Service List Details

    Service List Name

    TestAS2

    Service List Datatype

    XML

    Sending Member ID

    partyA

    Receiving Member ID

    partyB

    Priority

    Medium Priority

    Exit Service List

    <NONE>

    Services in List

    OutPrep

     

    gateway

    Figure 2-4  Service List Screen
    Screen capture of the Service list details.

  4. Click Add to add the Service List.
    To create a partnership
  1. From the Support interface, select Partnership.
  2. Select Add and specify the following field values:
  3. Table 2-5  Field Values for Creating a Partnership 

    Field

    Value

    Partnership Details

    Sending Member

    partyA

    Receiving Member

    partyB

    Partnership Type

    Application to Application

    Map Name

    <Leave blank>

    Document Type

    XML

    Partnership Description

    <Leave blank>

    Do not purge

    5

    Billing Code

    <Leave blank>

    Enable Trading

    On

    Incoming SMTP

    None
    None
    Not Signed or Encrypted (plain)

    Figure 2-5  Add Partnership Screen
    Screen capture of the Add partnership activity.

  4. Select Next and specify field values for Protocols. In Table 2-6, the first line in each Value cell gives a specific field value for the example. A general definition of the field is also given.
  5. Table 2-6  Fields Values for Outgoing Protocols 

    Field

    Value

    Outgoing Protocol

    HTTP for AS2

    The name for the Communications Agent is set in the ecx.ini file in the appropriate user-defined-x section at the User Visible Name field.

    Pre-Communications Service

    as2-pre-comm

    NOTE: You must specify as2-pre-comm or the communication session will fail.

    Delivery Timing

    Immediate

    NOTE: You must specify Immediate for this field or the communication session will fail.

    Endpoint URL

    http://<inbound host>:<inbound port>/AS2/inbound

    This is the destination to which the AS2 Outbound Server sends the HTTP POST.

    Security

    P

    You have the following options for this field:

    • P for plain messaging
    • S for signed messaging
    • E for encrypted messaging
    • B for signed and encrypted messaging

    MDN

    N

    You have the following options for this field:

    • N specifies no MDN acknowledgements
    • MP specifies plain (unsigned) MDNs
    • MS specifies signed MDNs

    Synchronous Response

    Y

    • Type Y to use the synchronous MDN return model.
    • Type N to use the asynchronous MDN return model.

    Compress Message

    N

    • Type Y to request compression.
    • Type N for no compression.

    MIME Subtype Override (Optional)

    XML

    Figure 2-6 shows the outgoing protocol specifications for this example.

    If you need to use security or reliability, you must create certificates as described in Chapter 3, "Creating Certificates for AS2 Messaging".

    Figure 2-6  Outgoing Protocol Screen
    Screen capture of Outbound protocol specification activity.


Setting up the Inbound Host

This section shows how to set up a partnership so that the inbound host can receive AS2 messages. Much of it is identical to the last section for setting up the Outbound host. Differences are noted.

Perform these procedures using the ECXpert installation on the machine you are using for the receiver.

    To create memberships
  1. Follow the same procedure and use exactly the same field information as shown in "To create memberships".
    To create a service list
  1. From the Support interface, select Services.
  2. Select Add and specify the field values given in Table 2-7.
  3. Table 2-7  Field Values for Creating a Service List

    Field

    Value

    Service List Details

    Service List Name

    AS2Test

    Service List Datatype

    XML

    Sending Member ID

    partyA

    Receiving Member ID

    partyB

    Priority

    Medium Priority

    Exit Service List

    <NONE>

    Services in List

    OutPrep

     

    gateway

  4. Click Add to add the Service List.

To create a partnership follow the same procedure and use exactly the same field information as shown in "To create a partnership" for Step 1 and Step 2.

    To create a partnership
  1. Select Next and specify the following for Protocols for the example, as shown in Figure 2-7:
  2. Table 2-8  Field Values for Creating a Partnership

    Field

    Value

    Outgoing Protocol

    FTP

    Pre-Communications Service

    <NONE>

    Delivery Timing

    Immediate

    Host Name

    ftpHost

    Port

    <Leave blank>

    User name

    The name of the ECXpert user

    Account

    <Leave blank>

    Password

    The password for the ECXpert user

    Outbound Transfer Mode

    BINARY

    Outbound Dir

    /tmp

    Create a temporary output directory and provide path here.

    Output Pattern

    outBoundMsg.xml

    This is the name of the output file.

    Inbound Dir

    <Leave blank>

    Inbound Pattern

    <Leave blank>

    Inbound File Type

    <Leave blank>

    Figure 2-7  Receiver’s Protocol Screen
    Screen capture of the Receiver's protocol information.

  3. Click Change.


Modifying the ecx.ini Configuration File

You must modify the ecx.ini file to identify the sender and receiver to ECXpert.

    To modify the ecx.ini file
  1. Open the ecx.ini using a text editor.
  2. Locate the AS2 Server section and modify the following fields:
  3. submit_sender = partyA

    submit_receiver = partyB

    submit_file_type = XML

    Leave submit_password blank.

  4. Save and exit the ecx.ini file.
  5. Shut down and restart the AS2 Server. See "Starting and Stopping the Servers" for instructions.


Sending a Document and Checking Results

Use the submission utility to submit a document from the outbound host, partyA.

    To submit a document
  1. Open the ECXpert submission utility and specify the field values in Table 2-9:
  2. Table 2-9  Field Values for Submitting a Document

    Field

    Value

    Sending Member

    partyA

    Receiving Member

    partyB

    File Name

    /tmp/outBoundMsg.xml

    (or whatever you called the output file and your temporary directory)

    File Type

    XML

    Figure 2-8  Submitting a Document Screen
    Screen capture of the Submitting a document activity.

    To check the results
  1. Record the tracking ID and view the results in ECXpert’s event log from both the sending and the receiving host machines.
  2. The following figures show successful submission for the sender and receiver.

    Figure 2-9  Event Log Screen
    Screen capture of Event log tracking.

    Figure 2-10  File Level Results Screen
    Screen capture of Five level results tracking.



Previous      Contents      Index      Next     


Copyright 2003 Sun Microsystems, Inc. All rights reserved.