CRM - Operating Systems and Middleware · Customer Profile Data Structure: E/R-Diagram (FMC) CRM...

12
Christian Kochs Jan Schaffner Jan Schulz-Hofen Gaurav Singh HASSO - PLATTNER - INSTITUTE for Software Systems Engineering CRM .NET Customer Relationship Management System A Project for Components Programming and Middleware, SS 2004 07/01/2004 HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 2 HASSO - PLATTNER - INSTITUTE Customer Management: Challenges Manage distributed Customer Data Serve multiple Users Ensure Consistency Store different Aspects for each Customer Profile

Transcript of CRM - Operating Systems and Middleware · Customer Profile Data Structure: E/R-Diagram (FMC) CRM...

Page 1: CRM - Operating Systems and Middleware · Customer Profile Data Structure: E/R-Diagram (FMC) CRM Base manages Customer Base Data (Profile Set) and object specific Security Privileges

Ä1

Christian KochsJan SchaffnerJan Schulz-HofenGaurav Singh

HASSO-PLATTNER- INSTITUTEfor Software Systems Engineering

CRM .NET

Customer Relationship Management System

A Project for Components Programming and Middleware, SS 2004

07/01/2004

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 2 HASSO- PLATTNER - INSTITUTE

Customer Management: Challenges

Manage distributed Customer Data

Serve multiple Users

Ensure Consistency

Store different Aspects for each Customer Profile

Page 2: CRM - Operating Systems and Middleware · Customer Profile Data Structure: E/R-Diagram (FMC) CRM Base manages Customer Base Data (Profile Set) and object specific Security Privileges

Ä2

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 3 HASSO- PLATTNER - INSTITUTE

Structure of Presentation

Requirements and Scenario of Application

Architecture of System

Technologies used

Live Demonstration with Technology Workshop

Development Process and Experiences

Outlook: Conceivable Extensions

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 4 HASSO- PLATTNER - INSTITUTE

Use Case Diagram (UML 2.0)CRM System

User

Admin

Manage SecurityPrivileges

Deploy Components**

Manage Customers

*

*

**

Add Component«extends»

Remove Component

«extends»

Add New Customer

Remove ExistingCustomer

Modify CustomerInformation

Read CustomerInformation

«extends»

«extends»

«extends»

«extends»

Enter Name

Edit ContactInformation

«extends»

Change Picture«extends»

Evaluate«extends»

Import OutlookContact Information

«extends»

Edit Memo

«extends»

«extends»

<<includes>>

Import Pics fromeRasm-Gallery«extends»

Authenticate

<<includes>>

<<includes>>

Page 3: CRM - Operating Systems and Middleware · Customer Profile Data Structure: E/R-Diagram (FMC) CRM Base manages Customer Base Data (Profile Set) and object specific Security Privileges

Ä3

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 5 HASSO- PLATTNER - INSTITUTE

Architecture of System

Multi-User-System

Follows Model-View-Controller (MVC) Pattern

Own Implementation of Naming Service (Registry)

Distributed Architecture (.NET Remoting)

Flexible Creation of Components (offered Functionalities)Dynamic management of heterogeneous and distributed componentsComponent Dynamics on both Client and ServerGUI is deployed together with specific component, not in the clientEach Component is responsible for its individual Data Storage

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 6 HASSO- PLATTNER - INSTITUTE

Compositional Structure (FMC)

View

ImageModel

EvaluationModel

ContactModel

Controller

Registry

R

R

R R

Clients Server

CRM BaseRegistered Components

R

ViewR

MemoModel

R

Customers

R

Dynamic Management of many heterogeneous and

distributed Components which carry their own

GUI and Data

Contact Data

R

R

R

R

R

Evaluation Data

Memo Data

ImageData

Page 4: CRM - Operating Systems and Middleware · Customer Profile Data Structure: E/R-Diagram (FMC) CRM Base manages Customer Base Data (Profile Set) and object specific Security Privileges

Ä4

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 7 HASSO- PLATTNER - INSTITUTE

Class Diagram (UML 2.0)

+ReadProfile()+ModifyProfile()+AddProfile()+RemoveProfile()+Authenticate()+GetTitlesForGui()+GetGuiExtensionsAsCoffList() : SortedList-UpdateModelList()

-ModelList : SortedList-AuthenticatedSessions : Hashtable

Controller

+GetRegisteredModels()+RegisterModel()+UnRegisterModel()

+ModelsTable : DataTable

Crm::Registry

+UpdateGuiExtensions()+UpdateTitleList()-ReadCustomer()-ModifyCustomer()-RemoveCustomer()-AddCustomer()

-GuiExtensions : SortedList-EntryList : SortedList-Ticket : int

Crm::View

* 1

+AddAspect()+RemoveAspect()+ModifyAspect()+ReadAspect()+GetGuiExtensionAsCoff()

#ClassBytes : byte[]#GUI_DLL_FILENAME : string#GUI_DLL_SIZE : int

AbstractModel

+AddAspect()+RemoveAspect()+ModifyAspect()+ReadAspect()

ContactModel

+ReadAspect()+AddAspect()+RemoveAspect()+ModifyAspect()

MemoModel

+FetchBody()+PutBody()+GetContentType()+Clear()

MemoGuiExtension

+FetchBody()+PutBody()+GetContentType()+Clear()

«interface»GuiExtensionInterface

+FetchBody()+PutBody()+GetContentType()+Clear()

ContactGuiExtension

1

1

CRM Base

Clients Server

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 8 HASSO- PLATTNER - INSTITUTE

Featured Technologies

Distribution and Communication via .NET Remoting:Server Activated Object (SAO)Singleton PatternBinary Formatter (Performance)

Dynamic Assembly Loading (of Components’ UIs)

Data Storage: MS SQL Server, ADO .NET, J2EE-Entity-Beans

Components implemented in C# and J#

COM-Interop: Microsoft Office Integration

Webservices via SOAP / XML

Page 5: CRM - Operating Systems and Middleware · Customer Profile Data Structure: E/R-Diagram (FMC) CRM Base manages Customer Base Data (Profile Set) and object specific Security Privileges

Ä5

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 9 HASSO- PLATTNER - INSTITUTE

System Startup Sequence (UML 2.0)Admin

:Controller

:Registry

:ContactModel

Additional Model

:WinAppView

User

start

start

start

start

start

login dialog

provide login/password

register model

synchronize customers’ data

synchronize customers’ data

get UI component

get UI component

confirm authentification

session id

request UI components

deliver UI component

request customer list

deliver UI component

CRM Base

register model

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 10 HASSO- PLATTNER - INSTITUTE

System Startup Sequence (UML 2.0)Admin

:Controller

:Registry

:ContactModel

Additional Model

:WinAppView

User

start

start

start

start

start

login dialog

provide login/password

register model

synchronize customers’ data

synchronize customers’ data

get UI component

get UI component

confirm authentification

session id

request UI components

deliver UI component

request customer list

deliver UI component

CRM Base

register model

Page 6: CRM - Operating Systems and Middleware · Customer Profile Data Structure: E/R-Diagram (FMC) CRM Base manages Customer Base Data (Profile Set) and object specific Security Privileges

Ä6

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 11 HASSO- PLATTNER - INSTITUTE

Customer Profile Data Structure: E/R-Diagram (FMC)

CRM Base manages Customer Base Data (Profile Set) and object specificSecurity PrivilegesEach Profile consists of one or moreCustomer AspectsAspects are managed individually byCRM .NET Components

ContentType is Linking Element between Model, View and Controller

TextAspect

Eval.Aspect

ContactAspect

ImageAspect

Aspect- ContentType- Body

Profile- Name- Security Privileges

1 n

Modular Architecture of CRM .NET requires modular Design of Data Structure

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 12 HASSO- PLATTNER - INSTITUTE

System Startup Sequence (UML 2.0)Admin

:Controller

:Registry

:ContactModel

Additional Model

:WinAppView

User

start

start

start

start

start

login dialog

provide login/password

register model

synchronize customers’ data

synchronize customers’ data

get UI component

get UI component

confirm authentification

session id

request UI components

deliver UI component

request customer list

deliver UI component

CRM Base

register model

Page 7: CRM - Operating Systems and Middleware · Customer Profile Data Structure: E/R-Diagram (FMC) CRM Base manages Customer Base Data (Profile Set) and object specific Security Privileges

Ä7

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 13 HASSO- PLATTNER - INSTITUTE

Dynamic Assembly-Loading in .NET

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 13 HASSO- PLATTNER - INSTITUTE

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 14 HASSO- PLATTNER - INSTITUTE

Framework Comparison

Extending the GUI dynamically in JavaDefining a Classloader extending the abstract ClassLoader Class

Page 8: CRM - Operating Systems and Middleware · Customer Profile Data Structure: E/R-Diagram (FMC) CRM Base manages Customer Base Data (Profile Set) and object specific Security Privileges

Ä8

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 15 HASSO- PLATTNER - INSTITUTE

Framework Comparison (contd.)

Extending the GUI dynamically in JavaUsing the defined GuiExtensionLoader to load a Class

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 16 HASSO- PLATTNER - INSTITUTE

Multi-User Facility

Global Data Synchronization

Let‘s open up a second View !

Page 9: CRM - Operating Systems and Middleware · Customer Profile Data Structure: E/R-Diagram (FMC) CRM Base manages Customer Base Data (Profile Set) and object specific Security Privileges

Ä9

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 17 HASSO- PLATTNER - INSTITUTE

COM Interop für Einbindung von MS Outlook (FMC)

.NET-Applikation RR

R

RCW COM-Objekt

Interop Marshaler (CLR)new()

.NET-Aufruf

Interop Assembly

COM-Aufruf

Managed Code Unmanaged Code

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 18 HASSO- PLATTNER - INSTITUTE

COM Interop

Create an Instance of the referenced COM-Component Use of the Type Library Importer (tlbimp.exe) to create a .NET InteropAssembly containing the Metadata of the COM Type Library

tlbimp <COM-Component> <.NET Interop Assembly> / <Options>

At Runtime, the .NET CLR will create an RCW for each COM ObjectRCW serves as a Bridge to the Unmanaged Code

Translating calls – consumes COM InterfacesMarshalling dataManaging lifetime of the wrapped object

In Source Code:

Page 10: CRM - Operating Systems and Middleware · Customer Profile Data Structure: E/R-Diagram (FMC) CRM Base manages Customer Base Data (Profile Set) and object specific Security Privileges

Ä10

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 19 HASSO- PLATTNER - INSTITUTE

Security Concept

User- and Group-based Authentication

Item-based Authorisation

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 20 HASSO- PLATTNER - INSTITUTE

Main Cycle

Provide authentication info and request

connection

Read reference auth. info from storage

Auth Info correctelse

Generate and provide unique session ticket

Store session ticket in RAM

Request operation (provide ticket and involved customer

profile)

else

CRM .NET Client Application(View)

CRM .NET Base(Controller)

Store ticket and corresponding user

identity in list in RAM

Authentication and Authorization (FMC Petri-Net)

Dynamics of Controller’s Session Management

Authentication and Authorization (FMC Petri-Net)

Dynamics of Controller’s Session Management

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 20 HASSO- PLATTNER - INSTITUTE

+ReadProfile(in ID : int, in Ticket : AuthTicket) : Profile+ModifyProfile(in ID : int, in ProfileToModify : Profile, in Ticket : AuthTicket) : void+AddProfile(in ProfileToAdd : Profile, in TitleToAdd : string, in Ticket : AuthTicket) : void+RemoveProfile(in ID : int, in Ticket : AuthTicket)+Authenticate(in username : string, in password : string) : AuthTicket+GetFilteredCustomerList(in Ticket : AuthTicket) : CustomerList

«interface»ControllerInterface

Page 11: CRM - Operating Systems and Middleware · Customer Profile Data Structure: E/R-Diagram (FMC) CRM Base manages Customer Base Data (Profile Set) and object specific Security Privileges

Ä11

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 21 HASSO- PLATTNER - INSTITUTE

Webservices: Talking to the J2EE-eRasm-Gallery

Client Proxy is required to access Webservice

Proxy Class is generated from WSDL-File by a tool

Proxy is instantiated in Client

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 22 HASSO- PLATTNER - INSTITUTE

Development Process and Experiences

Process Model applied: Extreme Programming (XP)

Testing with NUnit

Experiences with Tools

Microsoft Visual Studio 2003 .NET

Subversion and Tortoise Client

Microsoft (R) Web Services Description Language Utility

Type Library Importer (tlbimp.exe) for COM-Interop

Page 12: CRM - Operating Systems and Middleware · Customer Profile Data Structure: E/R-Diagram (FMC) CRM Base manages Customer Base Data (Profile Set) and object specific Security Privileges

Ä12

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 23 HASSO- PLATTNER - INSTITUTE

Outlook: Conceivable Extensions

FunctionalityStronger diversification within component hierarchyAdditional administration frontend

SecurityExtend our item-based authorization: Access Control ListsPossible to implement encryption-algorithm in additional remoting-layer

PerformanceImprove caching algorithmsIncrease efficiency of in-memory data structures

HPI, SS 2004: C.Kochs, J.Schaffner, J.Schulz-Hofen, G.Singh 24 HASSO- PLATTNER - INSTITUTE

Sources

Gosling, J., Yellin, F.: The Java Application Programming Interface, Vol. 1, Addison-Wesley, 1996

MSDN Library: msdn.microsoft.com

The Code Project: www.codeproject.com

Thai: .NET Framework Essentials, O’Reilly, 2001

The C# Corner: www.c-sharpcorner.com

Hamilton, MacDonald: ADO.NET in a Nutshell, O’Reilly, 2003