Business Services

In the same way that a business object is used to simplify a maintenance object, a business service can be used simplify a back-end service. The rating engine is a good example of a complex back-end service because it must satisfy a vast array of differing requirements. However, it is also true that the actual data required for a specific rating task can be quite simple. For example, if your script must calculate a simple cost per ton: you can pass the rating engine just a single service quantity and receive a calculated amount back.

Business services define alternative services to our internal services that are easier to work with. A Business Service provides a "simpler" data interface thus making interaction with the actual service easier. For example, it may flatten out complex collections and set up default values for other pieces of information (like a rate schedule).

Figure 1. Weight Calculation Business Service
Figure 2. Rate Application Service (about 30% of actual service)

As with the business object, the business service's interface to the internal service is defined using its schema. The schema maps the business service's elements to the corresponding elements in the internal service program's XML document. Keep in mind that many back-end services have child table collections (e.g., a collection of input service quantities, or a collection of output bill lines) and therefore the definition of where a business service property resides can be sophisticated. For example, defining a business service property like "Weight" requires the implementer to define:

Figure 3. Weight Charge Schema
Note: Flatten. We use the terms "flattening" and "flatten out" to describe a business service property that resides in a collection but is defined as a singular element.
Note: Schema Definition Tips. A context sensitive "Schema Tips" zone appears when you open the Business Service page to assist you with the schema definition syntax. The zone provides a complete list of the XML nodes and attributes available to you when you construct a schema.

XAI incoming messages and scripts support interaction with business services. You can also invoke a business service from a Java class.