Contents
Introduction
Components
Scenario
Design
Implementation Artifacts
About Active Endpoints

Quote Processing Demo Design Guide

Introduction

This document describes the design and implementation of the Quote Processing Demo Application.  The Quote Processing demo is based on a fictitious company 'Vintage Old Stock' which does repair work on classic cars.

This document first describes the components of the demo. Next, an overview of the scenario is provided, and finally high level design and implementation details are noted. 

Components

ActiveVOS Designer embeds a full featured version of the ActiveVOS Enterprise Server which has been configured with Apache Tomcat and an embedded database. This is the server used to host the demo environment.

The following default links are used to access the ActiveVOS Server Console, ActiveVOS Central and the Vintage Old Stock web page:

1) ActiveVOS Server Console: http://samples.activevos.com/activevos

2) ActiveVOS Central http://samples.activevos.com/activevos-central/login.jsp

3) Vintage Old Stock’s web page: http://samples.activevos.com/AVQuoteCllient/


The Vintage Old Stock’s web site is deployed at
[ActiveVOSDesignerDirectory]\Designer\designer\dropins\activevos\eclipse\plugins\org.activebpel.enginep_7.1.2\server\webapps

Note: The actual directory will vary slightly based on the specific version of ActiveVOS that you have installed (e.g. …\org.activebpel.engine_7.1.2)

 

Scenario

Title: Quote Estimation Process

Vintage Old Stock is a business that restores classic cars for its customers. The business of restoring a classic car to near mint condition involves many processes.

The Quote Estimation Process demonstration implements only Use Case (UC) 1: Request Quote process.


Actors

Bob: Customer

Roger: Chief Estimator

Stan: Interior Specialist (mechanic)

Chris: Exterior Specialist (mechanic)

Fred: Power Train Specialist (mechanic)

Mike: Manager

Use Cases

There are 4 major use cases relating to the restoration of a car for this demo

UC1: Request Quote

UC2: Accept Order

UC3: Source Parts

UC4: Perform Restoratoin

Customer Interaction

  1. Bob logs into the web site, select the 'Submit Car Restoration Quote Request' menu item
  1. Bob provides information about the vehicle that will allow Vintage Old Stock (VOS) to provide an estimate: make, model year, VIN (optional), and contact information.
  1. After submitting the request, Bob recieves an acknowledgement (returned to the browser, and sent via email).  The acknowledgement includes a Quote Request ID that he can use to obtain status on the quote process throughout the course of his interaction with Vintage Old Stock.
  1. Bob receives an email with the final quote. 
  1. Bob reviews the quote and can either abandon it, or proceed to the 'Accept Order' use case (not implemented for this demo).


Business Rules

Restoring cars using Vintage Old Stock's approach is fraught with risk. For example an estimate may be wildly under estimated based on imperfect information received from a customer or when the car is received and upon closer inspection, issues are revealed that may have been unknown to the customer. Reducing risk of not delighting the customer throughout the process is of the utmost importance to Vintage Old Stock.

To help ensure a great customer experience by ensuring that the right level of information is obtained to provide the best quote possible, rules based automation is used to accelerate the speed at which initial estimates are prepared. A rules engine is used to:

  1. Validate the request for quote from the customer, and

  2. Pre-populates input to the human task identifying what 'additional information' is required. This is used to accelerate Roger's work in providing a quote.



Quote Estimation Sub-process

After the rules engine validates the request, it's presented to Roger who performs an assessment of the work required. If he determines that detailed estimates are required, he delegates the task along to specialists.

Roger and other estimators can choose parts from a parts-list which is automatically generated based on the year, make and model of the car as defined in the request from the customer.  When the task forms are loaded in the client, a service is called which returns and populates the parts-list on the fly.

When each estimator completes his/her task, Roger is automatically (re)assigned the task to perform the final review of the estimates and approve them. Once he does, the final quote and bill of material is provided to the customer via mail.


Quote time to live

The amount of time a quote remains valid depends on a number of factors; as such this parameter is assigned dynamically. Once a quote expires, an email is sent to a customer informing him/her of this (for the purpose of this demo, there is no further recourse).

Business Rule: depending on the complexity of the work and the price of the estimate, a quote will be only be valid for a specific period of time.  By default, a quote will be valid for 15 days. The rules engine will return a value based on heuristics provided to it by 'the business'.

On-Event Action / Complex Event Processing

An important feature of ActiveVOS is the inclusion of a complex event processing engine. This provides a wide variety of capabilities that would not be possible with an orchestration engine alone.

Of course, even without a complex event processing engine, BPEL processes can do a certain amount of event processing.  They can have fault handlers that react to exceptional circumstances or event handlers that react to the events that are an expected part of the process flow.

The limitation, however, is that a BPEL process can only be used to react to events that are associated with a single process instance.

The problem is – applications, such as our Classic Car application, will often generate a large number of process instances every day.

The value of complex event processing is that it becomes possible to react, in real time, to _patterns_ that are discovered in the way that all these processes are acting over some period of time.

So we will look at the classic cars scenario, and imagine that the manager would like to know when the business is taking too long to generate estimates for potential customers.  To discover this, the manager sets up some threshold for the amount of time that estimates should take.  If the average response time over the last few days is over that threshold, the manager would like to get a new task in his inbox to look into what is causing the delays.

In order to measure the average response time, the manager will make sure that an event is generated at the point in the process where an estimation request is first determined to be valid.  Similarly, another event will be generated at the point in the process when the task has been successfully completed.


Design

Web Site

From the perspective of the customer:



Main Quote Generation BPEL Process


Validation process with Business Rules


Estimation Sub-process

Implementation Artifacts

Implementation

The implementation of the Classic Cars Renovation is carried out through four BPEL processes.

Primary Processes

The primary processes are the QuoteProcess.bpel and the EstimationProcess.bpel


Rules Process

To implement the 'Validate Request With Rules' activity, the JBoss Rules Engine was used.  We leverage ActiveVOS POJO integration to call the 'fireCarRules' method, and then wrapped the invocation using a BPEL process - thus exposing the rules as a service which is invoked as part of the Quote Process.



The rules (car_rules.dsl) used for the purpose of the demo are:

[condition][]there is a restoration request=info: CarRulesInfo()
[consequence][]set quote process time to live to: {value}=info.setTimeToLive({value});

[condition][]request does not contain model year=info: CarRulesInfo(quoteRequest.year == '' || quoteRequest.year == null  )
[consequence][]reject request=info.setValid( false );

[condition][]request contains no VIN and the car was built after year {value}=info: CarRulesInfo(quoteRequest.VIN == '' || quoteRequest.VIN == null, quoteRequest.year > '{value}'  )
[consequence][]ask the customer to provide VIN=info.setAdditionalActions('Ask customer to provide VIN number');

[consequence][]set reason of rejection to '{value}'=info.setReasonOfRejection('{value}');

[consequence][]add additional action '{value}'=info.setAdditionalActions('{value}');

Investigate Estimate Response Time Process - CEP

This process is invoked by the CEP engine when quotes are taking too long to generate on average. To discover this, EventStatements.eps is used to identify the threshold for the amount of time that estimates should take.  DetectEstimatesTakingTooLong.epp is used to launch the process which creates a new task in the Manager’s inbox to look into what is causing the delays.

About Active Endpoints

Active Endpoints (www.activevos.com) is the leading developer of visual orchestration systems. ActiveVOS empowers line of business project teams to create applications using services and industry standards, making their businesses more agile and effective. Active Endpoints’ ActiveVOS promotes mass adoption of SOA-enabled applications by focusing on accelerating project delivery time with a standards-based, easy to use system. Active Endpoints is headquartered in Waltham, MA with development facilities in Shelton, CT.

To find out how Active Endpoints can help your business, visit www.activevos.com, call +1 781 547 2948, or email us at info@activevos.com.