enticy group the a framework for web and winforms (client-server) applications “enterprise...

37
Entic y GROUP THE A Framework for Web and A Framework for Web and WinForms (Client-Server) WinForms (Client-Server) Applications Applications Enterprise Enterprise Software Software Architecture” Architecture”

Upload: hope-harper

Post on 28-Dec-2015

216 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

A Framework for Web and A Framework for Web and WinForms (Client-Server) WinForms (Client-Server)

ApplicationsApplications

““Enterprise Enterprise Software Architecture”Software Architecture”

Page 2: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

OutlineOutline

Short introductionsStart with a demo (Web and WinForms)Background and technical detailsCode walkthrough Building an applicationTopics in depth

Page 3: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Demo 1Demo 1Sample Application

Page 4: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

The goal isThe goal is

Provide a framework of reusable software components to simplify, speedup, reduce the cost, and assist in the creation of Web and WinForms applications which access databases and follow a business process

Page 5: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Technical SummaryTechnical Summary

Framework processes client requests (Web or Windows GUI), handles business logic, accesses database, and generates output (GUI, XML or XHTML) – full cycle

Encapsulates all database access as well as display and form handling

A generic solution for writing applications, but with a powerful extensibility model!

Page 6: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Technical DetailsTechnical Details

Reusable layered .NET objects– Our own design and architecture for a Web and

WinForms business applications. – Not using bound controls or web form controls– Object oriented

Data access encapsulation– Back-end independent approach for common database

providers– Automatic SQL generation for searches and CRUD (all

form handling)– Abstracted, key-based, optimistic-locking.

Page 7: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Technical DetailsTechnical Details

Metadata driven definition of forms, searches and security– Reusability– Flexible solutions – XML Based

Code generation vs. Runtime driven– One body of code– No orphan code – No regens

Page 8: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Technical DetailsTechnical Details

Stateless approach for both vertical and horizontal scalability of Web Apps– No object or object state maintained in memory

between requests – all gets persisted– Objects created when needed– Generic objects restore state quickly from

metadata, http request, and database– Objects can reside in “MTS” i.e. “Serviced

Component” in .NET (“application server”)

Page 9: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Technical DetailsTechnical Details

Multi-layer security and role-based logic– Application logic security is used to

authenticate and authorize user access to application and data

– login via Oracle, SqlServer, CustomDB, LDAP, Windows, Passport, Certificate, etc.

– Framework metadata-driven role-based security

– Native support for SSL

Page 10: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Technical DetailsTechnical Details

Layered Application Architecture – Core framework data components – Core framework utility components– Application extensibility components– Platform or presentation specific layer

(Web, WinForms, Web Service, etc.) Each encapsulate core framework

Page 11: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Web/client to ServerWeb/client to Server

DatabaseDatabase

IIS

BrowserBrowser

.NET

WAF ObjectWAF ObjectASPX ASPX pagespages

WAF ObjectWAF ObjectWAF ObjectWAF Object

WAF ObjectWAF Object

Cl ie

ntD

atab

ase

Ser

ver

WinFormsWinFormsWAF ObjectWAF Object

WAF ObjectWAF Object

Page 12: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Demo 2Demo 2Behind the sample application..

(Database, metadata, security..)

Page 13: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Framework ObjectsFramework Objects

Two general business application activities:

1. Searching for and listing record sets as well as selecting records to navigate or ‘open’ them (DBFind)

2. Opening a single record, showing a form, to create new, update, or delete (DBRecord).

Page 14: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Framework ObjectsFramework Objects

DBFind– Searching for data to:

View (decision support) Select as option (work flow, navigation) Select to modify (transactions)

– Invoking actions on found records

Page 15: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Framework ObjectsFramework Objects DBRecord

– CRUD (Create, Read, Update, and Delete)– Validation of data entry– Applying business rules – Transactions – Single record or set handling– Linked records and foreign keys – Edit Form– Result Set Table display

Page 16: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Framework ObjectsFramework Objects

Metastore– Holds Metadata for runtime data driven approach– XML DOM as a global singleton object– Holds all table definitions

Fields for each table Search definitions for each table Edit form definitions for each table

– Security on most items– System and Application Strings– Multi language support on all items

Page 17: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Framework ObjectsFramework Objects

Additional activities for most business applications– User Profile– Session Control– String dictionary– Request Object– URL builder– Instrumentation (trace, audit, profile, etc.)

Page 18: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Demo 3Demo 3Framework project walkthrough

Page 19: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

RuntimeRuntime

Cl ie

ntD

atab

ase

DatabaseDatabase

Ser

ver

IIS

Browser

DBFindDBFind

DBRecordDBRecord

MetastoreMetastore

ASPX ASPX pagespages

.NET

Page 20: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

XML to HTMLXML to HTML

XMLXMLMetadataMetadata

MetastoreMetastoreXML DOMXML DOM

User User interface and interface and navigationnavigation

BasicHTMLBasicHTML

Java ScriptJava Script

FormsForms

FieldsFields

TablesTables

SearchesSearches

FormsForms

SearchesSearches

DBFind or DBFind or DBRecordDBRecord

XML

HTML

SQL

XPATH, DOM API

DatabaseDatabase

Page 21: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Framework Object Life CycleFramework Object Life Cycle

CreateThe object

XML

HTML

SQL Restore all needed state

Persiststate

DestroyObject

Perform the work

ProcessInput

Compose output

HTML

SQL

Page 22: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Code Code ExampleExample

Dim Record As WAFdbComponents.DBRecord 

'Create a DBRecord objectRecord = New WAFdbComponents.DBRecord()

'Build the object from metadataIf Record.Build("Company", "EditForm", MainMetaStore, Profile) Then 'Identify and read the record from the database Record.PrimaryKeyValue = sPKey If Record.ReadRecord Then 'Output HTML-form populated with the fetched data Response.Write Record.EditFormHTML End IfEnd If

Page 23: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Demo 4Demo 4Code walkthrough (DBFind, DBRecord)

Page 24: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Framework ExtensionsFramework Extensions

Business Rules objectsSearch Rules objectsField validation objectsAuthentication objectProperty retrieverFunction overrides

Page 25: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

RuntimeRuntime

Cl ie

ntD

atab

ase

DatabaseDatabase

Ser

ver

IIS

Browser

DBRecordDBRecord

IBusinessRulesIBusinessRules

MetastoreMetastore

ASPX ASPX pagespages

Page 26: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Framework Object Life CycleFramework Object Life Cycle

CreateThe object

XML

HTML

SQL Restore all needed state

Persiststate

DestroyObject

Perform the work

ProcessInput

Delegate toBusiness Rules

HTML

SQL

Delegate toBusiness Rules

Compose output

Page 27: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Business Rules objectsBusiness Rules objects

Objects implementing the IBusinessRules interface

Assigned to a DBRecord object (in metadata) Runtime framework delegation

CanRead(..) IsValid(..) CanCreate(..) ReadComplete(..) CanEdit(..) WriteComplete(..) CanWrite(..) DeleteComplete(..) CanDelete(..)

CanDisplay(..) WriteAllComplete(..)

Page 28: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Search Rules objectsSearch Rules objects

Objects implementing the ISearchRules interface

Assigned to a DBFind object (in metadata)

Runtime framework delegation CanDisplaySearch(..)

CanExecute (..)

Page 29: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Field validation objectsField validation objects

Objects implementing the IFieldValidation interface

Assigned to a Field objectRuntime framework delegation

IsValid(..)

Page 30: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Demo 5Demo 5Business rule code walkthrough

Page 31: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Web FrameworkWeb Framework

ASP.NET layerPages derived from -

System.Web.UI.PageEncapsulates dbComponents workHandles HTTP requestsOrchestrates HTML response

Page 32: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

DatabaseDatabase

Browser

DBFindDBFind

DBRecordDBRecord

MetastoreMetastore

System.Web.UI.PageSystem.Web.UI.Page

ASP.NET

ProfileProfile

SessionSession

webComponents

dbComponents

WafControllerPageWafControllerPage

WafFormPageWafFormPage

WafFormWafForm(Application derived form)(Application derived form)

html

http request (state, action-verb)

Page 33: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Demo 6Demo 6Web framework walkthrough

Building an Application!

Page 34: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

WinForms (Client/Server)WinForms (Client/Server)

WinForms.NET layerMDI Application ClassForms derived from –

System.Windows.Forms.FormEncapsulation of dbComponentsUI driven (no UI generation)

Page 35: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

DatabaseDatabase

User

DBFindDBFind

DBRecordDBRecord

MetastoreMetastore

WinForms.NET

ProfileProfile

guiComponents dbComponents

Main Application window

File Edit Tools

FormDbFindFormDbFindInherits Inherits System.Windows.ForSystem.Windows.Forms.Formms.Form MyFormMyForm

Inherits Inherits FormDbRecordFormDbRecord Inherits Inherits System.Windows.System.Windows.Forms.FormForms.Form

Page 36: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Demo 7Demo 7WinForms framework walkthrough

Page 37: Enticy GROUP THE A Framework for Web and WinForms (Client-Server) Applications “Enterprise Software Architecture”

EnticyGROUP

THE

Topics in depthTopics in depth

UI generation - XML and HTML pages (using customizable XSLTs if desired),

SQL generation Back-end independent Generic exception handling Business rule extensibility Profile Session ...