migrating traditional business rules applications to the cloud

Post on 25-Feb-2016

62 Views

Category:

Documents

1 Downloads

Preview:

Click to see full reader

DESCRIPTION

Migrating Traditional Business Rules Applications to the Cloud. Alexander Schmidt aschmidt@inrule.com http://www.inrule.com. April 20, 2010. Overview. Introduction to BRE and Cloud Objectives and Solution Performance and Scalability Simulation in the Cloud Advantages and Conclusions. - PowerPoint PPT Presentation

TRANSCRIPT

Migrating Traditional Business Rules Applications to the CloudAlexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

April 20, 2010

2Alexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

Overview• Introduction to BRE and Cloud• Objectives and Solution• Performance and Scalability• Simulation in the Cloud• Advantages and Conclusions

3Alexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

Where Business Rules Are Found

Components of a Business Rule Management System (BRMS)

Introduction to Business Rules

Processes MainframeSystems

Spreadsheets& Documents Databases Application

Code

AuthoringCreate and test business processes using business rules

Rule RepositoryStore, organize,report and auditbusiness policies

Rule Execution and MonitoringDeploy and monitor automated business policies as they execute.

4Alexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

• Cloud computing is Internet-based computing, whereby shared resources, software and information are provided to computersand other deviceson-demand, like apublic utility.

• 3 major players:Microsoft AzureAmazon Elastic CloudGoogle App Engine

Introduction to the Cloud

Cloud Application

Compute Storage

FabricConfig

Application

5Alexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

Objectives• Minimize TCO• Simplify BR management• Rules rollout should be quick• Rules repository

Travel and transportationHealthcare

Logistics

Banking

Finances

Insurance

6Alexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

• Ruleapps are discoverable, other departments within an organization, i.e. feduciary, riskmanagement can get access,perform audit etc.

• Can become a knowledge base thatis extendable as new services are added tothe service bus, a step towards SaaS.

• Better security due to centralization of data, increased security-focused resources, etc.

• Great opportunity for applicationsin different industries includingHealth, R&D, Education.

Towards BRMS Service Bus

Service Bus

Cloud Compute & Storage

Corporation

Security Service

Employees

Cloud CRM

Cloud ERP

Users

8Alexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

Solution• Traditional BRMS migration to Cloud• Parallel execution of rule applications (rule app

and rule parallelism)• Cloud-based rule repository

Functional OverviewArchitecture Overview

9Alexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

RuleApp

Schema

Rules

AooFabricServer

Architecture Overview

AooFabricServer

RuleApp

RuleApp

State

Repository

SDS

Microsoft Azure

Entities

Calculations Vocabulary

Decisiontables Constraints

EndPoints

Xml Schema Data

Alexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

W2wp.exe (AppPool worker)

Functional Overview

Rule app Modules

Rule Engine

AppFabric Modules

PowerShell: AppFabric Command-lets

AppDomain

Code Service

Workflow Service

WAS

ConfigCache Service

Event Management

Service

WorkflowManagement

Service

ASP.NET Code

Repository

MonitoringStore

10

1

2

4

3

11Alexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

• Breaking down into chunks▫ Working Memory▫ Network

• State management▫ Retrieving State▫ Storing State

• Optimizations▫ Rete Algorithm (caching, logic optimiz.)▫ Sequential vs. Parallel rule execution

Performance and Scalability

12Alexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

Repository Provider for the CloudDesign•Easy to design and implement since relational storage is provided.•Provides highly available and secure service which is easy to program and provision.

•Can be accessed from anywhere, handles the challenges of getting through firewalls without opening new ports for exposed applications.

•Tighter integration with existing components.

Implementation• .Net-based, developers with right skills are there•Possible to provide cloud-based service that can be used by either on-premises applications or global applications.

Maintanance•Users can avoid capital expenditure on hardware, software and services.•Microsoft’s data centers frees the enterprise from the responsibility and expense of managing its own servers, turning capital expenses into operating expenses.

• If the application has spikes in usage—maybe it’s an on-line store that must handle the holiday rush—letting Microsoft maintain the large server base required for this can make economic sense.

13Alexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

Simulation• Goals

▫ Verify BRMS in the Cloud ▫ Evaluate performance and scalability▫ Check architecture decisions affecting BRE applications

specific to Cloud• Methods

▫ A sample ruleapp executed in the Cloud (AppFabric, Service Bus)

▫ Repository in the Cloud

14Alexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

A sample ruleapp executed in the Cloud• Rule application with an entity• Entity contains 2 fields and

returns sum of both as a result// Create the rule appRuleApplicationDef ret = new RuleApplicationDef("Demo");

// Add EntityEntityDef entity1 = new EntityDef("TestEntity");ret.Entities.Add(entity1);

// Add Fieldsentity1.Fields.Add(new FieldDef("Value1", DataType.Number));entity1.Fields.Add(new FieldDef("Value2", DataType.Number));entity1.Fields.Add(new FieldDef("Result", "Value1 + Value2", DataType.Number));return ret;

15Alexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

• Tests performed in▫ On-premises environment

Intel Core i5, 4GB, 2.27 GHz 1 Instance

▫ Cloud environment Windows Azure Guest OS 1.2 10 Instances

Sample Ruleapp Statistics

1 10 100 150 200 250 300 500

020406080

100120140160180200

CloudLocal

Number of requestsEx

ecut

ion

tim

e, s

ec.

16Alexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

Repository in the Cloud

Local DB

SQL Azure

17Alexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

• Goals▫ Deploy repository to

Cloud▫ Measure performance

of repository ops• Methods

▫ Test rule application 3.8MB▫ Create, checkout, check in tests

Repository in the Cloud Statistics

CreateCheckout

Checkin

020406080

100120140160180200

Local

Cloud

LocalCloud

Operation

Exec

utio

n ti

me,

sec

.

18Alexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

• Not all features are supported

• Replication and file management is automatic

• Conceptually similar to an on-premise instance of SQL Server

• Same Relational Data Model

SQL Azure vs. Local SQL ServerTransact-SQL Features Supported Transact-SQL Features Unsupported

Constants Constraints Cursors Index management and

rebuilding indexes Local temporary tables Reserved keywords Stored procedures Statistics management Transactions Triggers Tables, joins, and table variables Transact-SQL language elements

such as o Create/drop databaseso Create/alter/drop tableso Create/alter/drop users

and loginso and so on.

User-defined functions Views, including sys.synonyms

view

Common Language Runtime (CLR)

Database file placement Database mirroring Distributed queries Distributed transactions Filegroup management Global temporary tables Spatial data and indexes SQL Server configuration options SQL Server Service Broker System tables Trace Flags

19Alexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

• Oracle 11gR2 through Amazon Web Services (AWS)

• Real Applications Cluster (RAC), Automatic Storage Management (ASM), and Storage Grid in the Cloud

• Repository is similar to the one for SQL Server• Same product in the Cloud as the on-premises• AMI (Amazon Machine Image) is available

Oracle in the Cloud

21Alexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

Advantages and Conclusions• Centralized repository• Improved security (centralized)• Unlimited scalability• Recovery• Improved application performance• Minimized TCO

22Alexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

References:▫ Windows Azure

http://www.microsoft.com/windowsazure/ ▫ Windows Server AppFabric Architecture

http://blogs.msdn.com/endpoint/archive/2010/03/24/windows-server-appfabric-architecture.aspx

▫ Oracle in the Cloud http://www.oracle.com/technology/tech/cloud/pdf/oracle-in-the-c

loud-datasheet.pdf

▫ Developing a Cloud-based Virtual Machine http://cloudslam09.com/content/developing-cloud-based-virtual-

machine-81.html▫ Migrating Traditional Business Rules Applications to

the Cloud http://www.alexschmidt.net/research/migrating-traditional-bre-t

o-cloud.pdf

23Alexander Schmidtaschmidt@inrule.comhttp://www.inrule.com

Q&A

top related