JBoss.orgCommunity Documentation

Chapter 7. Building JAIN SLEE Services

7.1. Creating a JAIN SLEE Service
7.2. Editing a JAIN SLEE Service
7.2.1. Edit Service Identity
7.2.2. Edit Service Root SBB
7.3. Deleting a JAIN SLEE Service

EclipSLEE provides means to create, edit and delete JAIN SLEE Services.

The JAIN SLEE Service does not have a Maven module, instead it's part of the Deployable Unit module resources.

To create a new JAIN SLEE Service, expand completely the du module folders, right-click on the resources folder and select NewOther ... as shown below.

Figure 7.1. Creating a new JAIN SLEE Service in EclipSLEE


A dialog should appear. Expand the JAIN SLEE item and choose JAIN SLEE Service. The dialog should now look like the following:

Figure 7.2. Creating a new JAIN SLEE Service in EclipSLEE


Click Next to get the following dialog:

Figure 7.3. Selecting the package and name for a new JAIN SLEE Service in EclipSLEE


The source folder dialog will be completed if NewOther ... has been selected from right-clicking on the deployable unit module resources folder. Otherwise it may need to be chosen by selecting Browse... and selecting the desired location.

Name the service; the name must end with "service.xml", then click Next to specify the service's SLEE identity.

Figure 7.4. JAIN SLEE Service Identity dialog in EclipSLEE


The Name, Vendor and Version fields are mandatory and are used by the SLEE to identify the event. The description field is optional, but strongly recommended to be completed to allow easy identification of the service in future.

After completing these fields click Next to select a root SBB.

Figure 7.5. JAIN SLEE Service Root SBB selection using EclipSLEE


All available root SBBs are listed in the table. Select the one that should be used for this service.

Available Components Missing?

At the moment, in order for the available components to be listed in the wizard, they need to be part of the classpath. For instance if you want to use an external root SBB for your project, you will need to add it as a Maven Dependency and be part of classpath first. Refer to Section 3.3.1, “Adding a New Maven Dependency” on how to do it.

My SBB is not listed.. why?

Check the following if your SBB is not listed:

  • Does the SBB have at least one initial event? That is, an event with direction Receive or FireAndReceive, marked as initial-event and has at least one initial event selector.

  • Is the SBB shown in the project source list? If not, please cancel the Service wizard, refresh the project so it shows up and try again.

Specify the default event priority, and if available for your root SBB, enable or disable Specify service address profile table as required.

Click Finish to create the service.

The service descriptor is created in the specified folder and opened for editing in the workspace. The resulting workspace can be seen below.

Figure 7.6. JAIN SLEE Service created in workspace using EclipSLEE


It is possible with EclipSLEE to edit existing components. When right-clicking on the *-service.xml descriptor a similar menu should be shown:

Figure 7.7. Editing a JAIN SLEE Service through Service XML file


After selecting the desired Service, the menu shown allows you to select one of the following actions to modify:

It is possible with EclipSLEE to delete existing components. Right-clicking in the JAIN SLEE Service XML descriptor file (see Section 7.2, “Editing a JAIN SLEE Service”) and selecting the Delete option.

A confirmation dialog similar to the following should be presented:

Figure 7.10. Deleting a JAIN SLEE Service confirmation dialog


Impossible to undo this operation!

Deleting a component is an irreversible operation, so it should be used carefully.