Starting a Business Service

Starting a business service involves listing all the available business services and then selecting a business service to start.

The following example shows how calls to the objectAPI can be used to start and update a business service.

Starting a Business Service

Procedure

  1. When you login to an application, listCategories is called and all the available categories are listed in the Business Services tab.
  2. When the user clicks on a category, queryBusinessServices is called and all the business services under the selected category are displayed. The response contains the details of all the business services under the selected category.
  3. Selecting a business service displays the details of that business service on the client, which are obtained from the response message of the queryBusinessServices call.
  4. When the user clicks the button to start a new instance of the business service, it calls startBusinessService and passes the module name, process name, and version number. The values for these parameters can be obtained by calling queryBusinessServices or listBusinessServices.

    The response returns the execution state, process ID, activity ID, and the payload.

  5. If the business service has a form associated with it, getBusinessServiceDetailsByModule is called. The response contains the form details, which are then passed on to the Forms Adapter.
  6. The Forms Adapter parses the data and displays an appropriate Form to the end user. Similarly, any input provided in the form is processed by the Form Adapter and handed back to the servlet.

    For details about how the data is passed to, and received from, the Forms Adapter, see Forms.

    Note: For details about the TIBCO Forms APIs, see the TIBCO Business Studio Forms User’s Guide.
  7. Once the user enters values in the form fields and clicks Submit, updateBusinessService is called with the payload containing the values entered by the and user. Repeat steps Step 5 and Step 6 until the business service completes or is cancelled.

    The response returns the execution state, process ID, activity ID, and the payload. If the business service is complete, the execution state is COMPLETED.