Adding a Service

In this section:

How to:

Services are executable Java procedures that are used to handle the business logic of a message.

A service is the business layer that incorporates the logic for encapsulating the business process which interacts with other distributed component services to provide transactions for business "state" information. This business layer incorporates the application business logic. In an iWay Service Manager environment, business logic consists of one or more services acting on an input document. Services can be stacked, such that the output of one service is passed to the next service, or multiple services can be executed in parallel. It is recommended that services be added using iWay Designer.

Services are written in standard Java language and can make use of any available Java libraries or services. iWay Software supplies several predefined services that you can use as part of your business logic. For more information on the specific properties of iSM pre-defined services, see the iWay Service Manager Component and Functional Language Reference Guide.


Top of page

x
Procedure: How to Configure a Service

To configure a service using the iWay Service Manager Administration Console:

  1. In the left console pane of the Registry menu, select Services.

    The Services pane opens.

  2. Click Add.

    The Service Type pane opens.

  3. Select a type of service from the list, for example, File Emit Agent (com.ibi.agents.XDFileEmitAgent).

    You can also type the class name of a service that is packaged in a .JAR file, which is available in the Java class path.

  4. Click Next.

    The configuration parameters pane for the File Emit Agent service opens.

  5. Provide the required configuration parameters for the service, and click Next.

    The Name and Description pane opens.

  6. Provide a name and, optionally, a description, for the service, and click Finish.

    The service is added to the list in the Services pane.

    After a service is added to iWay Service Manager, you can assign it to a process that is used to configure a route. For more information, see Configuring Channels.


Top of page

x
Procedure: How to Modify a Service

To modify a service:

  1. Click the service name you wish to modify in the main Services pane.

    The configuration parameters pane for the service you are modifying opens.

  2. Make your changes to the service properties as required.
  3. Click Update.

    The service is now modified.


Top of page

x
Procedure: How to Delete a Service

To delete a service:

  1. Click the check box next to the service you wish to delete, for example, FileEmitService.
  2. Click Delete.

    A confirmation dialog box opens, prompting you to confirm deletion of the service.

  3. Click OK.

    The service is deleted from the system.

    Tip: To delete more than one service at once, you can select multiple check boxes in the Services pane and click Delete.


Top of page

x
Procedure: How to Rename a Service

To rename a service:

  1. Click the check box next to the service you wish to rename, for example, FileEmitService.
  2. Click Rename.

    The Rename pane opens.

  3. Type a name, for example, TestService, in the New Name field and click Finish.

    You are returned to the main Services pane.

    The new name for the service you provided is shown.


Top of page

x
Procedure: How to Copy a Service

To copy a service:

  1. Click the check box next to the service you wish to copy, for example, FileEmitService.
  2. Click Copy.

    A copy of the service is made, as shown in the following image.

    Making copies of a service is useful for versioning and testing purposes.

    Tip: To copy more than one service at once, you can select multiple check boxes in the Services pane and click Copy.


Top of page

x
Multiple Services

If your requirements include using multiple services for complex business logic, you must create a process flow with multiple services using iWay Designer. For more information on creating process flows, see the iWay Designer User’s Guide.


Top of page

x
Conditional Routes

In iWay Service Manager, a route has the responsibility for handling one aspect of document processing. When multiple routes are defined, configuring conditional settings at the route level allows you to control the order in which the services execute. For more information, see Configuring Channels.


Top of page

x
Configuring Acknowledgment Services

Acknowledgment services return an acknowledgment document to a client indicating that a request or input document was received. You can use acknowledgment services with adapters such as the iWay Adapter for EDI X12. For more information, see the iWay Integration Solution for EDI User's Guide.

The acknowledgment document also indicates whether the input is valid and is being processed or if the input failed validation. The actual processing of the document is performed by other configured services, for example, TRANSFORM and others.

During processing of acknowledgment services, the special register ackresponse is set to '1'. This simplifies condition testing for the associated emitter components so that some are used for sending the acknowledgment and some are used for other purposes. The register is set regardless of whether an acknowledgment or a NAK is being emitted by the service.



x
Procedure: How to Define an Acknowledgment Service

To define an acknowledgment service:

  1. In the left console pane of the Registry menu, select Services.

    The Services pane opens.

  2. Click Add.

    The Service Type pane opens.

  3. Select EDIX12AckAgent (com.ibi.agents.XDX12AckAgent) from the drop-down list.
  4. Click Next.

    The configuration parameters pane for the EDIX12AckAgent service opens.

  5. Select the default parameters for this service, and click Next.

    The Name and Description pane opens.

  6. Provide a name, for example, X12_Ack, and optionally, a description, for this service, and click Finish.

    The service is added to the list in the Services pane.

    After the EDIX12AckAgent service is defined, you can create a new process and assign this service to that process. For more information, see the iWay Integration Solution for EDI User's Guide.


iWay Software