Design I: Web Application Architecture and Patterns Peter Dolog dolog [at] cs [dot] aau [dot] dk Intelligent Web and Information Systems September 23, 2010
This Lecture IS Architecture for the Web, MVC Model Patterns View Patterns Controller Patterns 2 Peter Dolog, Web Engineering, Design I
3 Historical Perspective presentation layer resource management layer application logic layer client information system 1. define access channels and client platforms 2. define presentation formats and protocols for the selected clients and protocols 3. define the functionality necessary to deliver the contents and formats needed at the presentation layer 4. define the data sources and data organization needed to implement the application logic top-down design Copyright Springer Verlag Berlin Heidelberg 2004
4 Peter Dolog, Web Engineering, Design I client presentation layer resource management layer application logic layer information system 3-tier architecture middleware Copyright Springer Verlag Berlin Heidelberg 2004
5 Peter Dolog, Web Engineering, Design I client resource management layer application logic layer information system N-tier architecture middleware presentation layer Web server Web browser HTML filter Copyright Springer Verlag Berlin Heidelberg 2004
Model-View-Controller 6 Peter Dolog, Web Engineering, Design I Model ViewController
Model
Domain Model 8 Peter Dolog, Web Engineering, Design I
Database 9 Peter Dolog, Web Engineering, Design I
Model as a Transaction Script 10 Peter Dolog, Web Engineering, Design I
Structuring Domain Model: Analysis Patterns 11 Peter Dolog, Web Engineering, Design I (C) Martin Fowler: Analysis Patterns
12 Peter Dolog, Web Engineering, Design I Accountability A relationship of responsibility between responsee and responsible Organizational structures Employments Contracts
13 Peter Dolog, Web Engineering, Design I Address Book (C) Martin Fowler: Analysis Patterns
14 Peter Dolog, Web Engineering, Design I Party (C) Martin Fowler: Analysis Patterns
15 Peter Dolog, Web Engineering, Design I Organization Structure with Explicit Levels (C) Martin Fowler: Analysis Patterns
16 Peter Dolog, Web Engineering, Design I Organization Supertype (C) Martin Fowler: Analysis Patterns
17 Peter Dolog, Web Engineering, Design I Two organizational hierarchies (C) Martin Fowler: Analysis Patterns
18 Peter Dolog, Web Engineering, Design I Typed Relationships (C) Martin Fowler: Analysis Patterns
19 Peter Dolog, Web Engineering, Design I Rules (C) Martin Fowler: Analysis Patterns
20 Peter Dolog, Web Engineering, Design I Accountability (C) Martin Fowler: Analysis Patterns
21 Peter Dolog, Web Engineering, Design I Knowledge and operational levels (C) Martin Fowler: Analysis Patterns
22 Peter Dolog, Web Engineering, Design I Party Type Generalizations (C) Martin Fowler: Analysis Patterns
23 Peter Dolog, Web Engineering, Design I Hierarchic Accountability Type (C) Martin Fowler: Analysis Patterns
24 Peter Dolog, Web Engineering, Design I Leveled Accountability Type (C) Martin Fowler: Analysis Patterns
25 Peter Dolog, Web Engineering, Design I Subtypes of Acountability Types (C) Martin Fowler: Analysis Patterns
26 Peter Dolog, Web Engineering, Design I Operating Scopes (C) Martin Fowler: Analysis Patterns
27 Peter Dolog, Web Engineering, Design I Accounting Tracing how money move througout the company Tacking of earnings and expenditures Posts of money and goods to record – entries
28 Peter Dolog, Web Engineering, Design I Account (C) Martin Fowler: Analysis Patterns
29 Peter Dolog, Web Engineering, Design I A Transaction with Two Entries (C) Martin Fowler: Analysis Patterns
30 Peter Dolog, Web Engineering, Design I Instance Example (C) Martin Fowler: Analysis Patterns
31 Peter Dolog, Web Engineering, Design I Multiledged Transactions (C) Martin Fowler: Analysis Patterns
32 Peter Dolog, Web Engineering, Design I 2-legged transaction without entries (C) Martin Fowler: Analysis Patterns
33 Peter Dolog, Web Engineering, Design I Summary and Detail Accounts (C) Martin Fowler: Analysis Patterns
34 Peter Dolog, Web Engineering, Design I Account hierarchies without separating summary and detail accounts (C) Martin Fowler: Analysis Patterns
35 Peter Dolog, Web Engineering, Design I Posting Rules Multiplied by a Factor or a method to calculate an entry (C) Martin Fowler: Analysis Patterns
36 Peter Dolog, Web Engineering, Design I Individual Instance Methods with Singletons (C) Martin Fowler: Analysis Patterns
37 Peter Dolog, Web Engineering, Design I Implementation with Strategy Pattern (C) Martin Fowler: Analysis Patterns
38 Peter Dolog, Web Engineering, Design I Implementation with Internal Case Statement (C) Martin Fowler: Analysis Patterns
39 Peter Dolog, Web Engineering, Design I Implementation with Parametrized Method (C) Martin Fowler: Analysis Patterns
40 Peter Dolog, Web Engineering, Design I Posting Rules for Many Accounts (C) Martin Fowler: Analysis Patterns
41 Peter Dolog, Web Engineering, Design I Account finder and Eligibility Conditions (C) Martin Fowler: Analysis Patterns
42 Peter Dolog, Web Engineering, Design I Acount Groups: Accounting Practices (C) Martin Fowler: Analysis Patterns
43 Peter Dolog, Web Engineering, Design I Sources for Transactions (C) Martin Fowler: Analysis Patterns
44 Peter Dolog, Web Engineering, Design I Balance Sheet and Income Statement (C) Martin Fowler: Analysis Patterns
45 Peter Dolog, Web Engineering, Design I Corresponding Accounts (C) Martin Fowler: Analysis Patterns
46 Peter Dolog, Web Engineering, Design I Supporting Inventories (C) Martin Fowler: Analysis Patterns
47 Peter Dolog, Web Engineering, Design I Multiple Summary Accounts (C) Martin Fowler: Analysis Patterns
48 Peter Dolog, Web Engineering, Design I Derived Accounts (C) Martin Fowler: Analysis Patterns
49 Peter Dolog, Web Engineering, Design I Expenses to Abandon Accounting Model (C) Martin Fowler: Analysis Patterns
Interesting Domain Models 1 50 Peter Dolog, Web Engineering, Design I (C) Martin Fowler: Analysis Patterns
View
Template View 52 Peter Dolog, Web Engineering, Design I (C) Martin Fowler: Patterns of Enterprise Application Integration
Transform View 53 Peter Dolog, Web Engineering, Design I (C) Martin Fowler: Patterns of Enterprise Application Integration
Two Step View 54 Peter Dolog, Web Engineering, Design I (C) Martin Fowler: Patterns of Enterprise Application Integration
Example on two step view2 55 Peter Dolog, Web Engineering, Design I (C) Martin Fowler: Patterns of Enterprise Application Integration
Controller
Page Controllers 57 Peter Dolog, Web Engineering, Design I (C) Martin Fowler: Patterns of Enterprise Application Integration
Application Controller 58 Peter Dolog, Web Engineering, Design I (C) Martin Fowler: Patterns of Enterprise Application Integration
Sequence view 59 Peter Dolog, Web Engineering, Design I (C) Martin Fowler: Patterns of Enterprise Application Integration
Other Patterns
Data Mapper 61 Peter Dolog, Web Engineering, Design I Story Mapper Insert Update Delete
Row Data Gateway 62 Peter Dolog, Web Engineering, Design I StoryGateway Type Title Insert Update Delete
Active Record 63 Peter Dolog, Web Engineering, Design I (C) Martin Fowler: Patterns of Enterprise Application Integration
Lazy Load 64 Peter Dolog, Web Engineering, Design I (C) Martin Fowler: Patterns of Enterprise Application Integration
Service Layer 65 Peter Dolog, Web Engineering, Design I (C) Martin Fowler: Patterns of Enterprise Application Integration