Business objects

Business objects are representations of business objects such as a Customer, Product or Order. The primary purpose of a business object is to hold the data that is evaluated by event rules at run time. The data that populates a business object does exist in the enterprise applications, but it typically does not exist in a single record or structure.

The fields in a business object can be populated from various sources. For example, a business object that describes a customer might contain the following fields: customer ID, name, home address, phone, email, lifetime value, and last order date. Often these fields come from different sources as shown in the following diagram:

Business objects contain fields that can come from different sources

The business object as defined to Decision Server Events is the ideal representation of the business object. It serves as a template for sharing data, containing a number of fields that can be populated from many different business applications across the enterprise. Each field includes the name and type of the information, as well as an optional definition for how to get a value, if none is supplied with the event.

Fields in business objects are referenced when building rules, filters, and action objects.

Business objects are used during the evaluation of event rules in the event runtime. The values of fields in the business objects are populated at run time in one of two ways:

The definition type for a business object field in Event Designer indicates how the field is to be populated, if it is not constructed from an event object:

There are several ways to create a business object:
  • As a new business object: You start with an empty business object and add new fields that match your business definition of the object.
  • From an Event object. The business object is created with the same fields as the event object.
  • Directly from an existing data connection. Define the data connection to the business object and then identify the key fields.
  • As a generated business object from a new business rules data connection. Use the New Data Connection function to create a new business rule data connection and generate business objects from ruleset parameters.

Typically, business object instances are transient. (For information about keeping business objects across events within a context, see Sharing data across events in a context.) Business objects exist for as long as they are required for event evaluation and action construction. At run time, when an event is retrieved by the event runtime, corresponding business object instances are created. Which business objects are created and the number of instances of each business object depends on how the event is structured.

When the event is processed, the event runtime evaluates all the rules for that event. When the event runtime encounters a field, whose value was not supplied from an event object, the data resolver attempts to retrieve the missing data based on the definition of the field. Then, event rule evaluation continues. For those event rules that evaluate to true, the event runtime builds an associated action instance. When the event rule evaluation for the event is complete, the corresponding business object instances are removed from memory.