Triggered actions runtime workflow

The following triggered actions workflow occurs at Unica Interact runtime.

  1. When the event or event pattern is triggered, the message handler is invoked. The message handler is a type of an event action.
  2. The message handler evaluates the message’s eligibility condition. The result determines which offer is delivered and the candidate outbound gateways to send the offer.
    1. If the offer is configured to be delivered later through the selected touchpoint (channel), it is persisted into UACI_TriggeredMessages table.
    2. Otherwise, the offer is delivered immediately.
  3. The message handler then determines the dispatcher based on the channel.
  4. The offer information and the session data is passed to the dispatcher.
  5. The dispatcher adds the offer into a queue for the selected gateway.
  6. When the consumer side, which may or may not run in a different JVM if the dispatcher is a JMS queue, receives the offer, it invokes the gateways to send the offer.
  7. Periodically, a thread checks the database for delayed offers, loads them to be delivered, and sends the offers to the dispatchers corresponding to the touchpoints (channels) that were determined in step 2.

If an error occurs in items 1 - 5 or 7, the offer is persisted into the database with the status marked as FAIL. If no errors occur, the offer is considered to be delivered successfully.

If an error occurs in step 6, the handling depends on the implementation of the consumer and/or the gateway. However, if the consumer also runs in the same application server, an error is logged.

Triggered message workflow