Presentation is loading. Please wait.

Presentation is loading. Please wait.

1 Software Architecture CS 414, Software Engineering I Mark Ardis, Rose-Hulman Institute January 14, 2003.

Similar presentations


Presentation on theme: "1 Software Architecture CS 414, Software Engineering I Mark Ardis, Rose-Hulman Institute January 14, 2003."— Presentation transcript:

1 1 Software Architecture CS 414, Software Engineering I Mark Ardis, Rose-Hulman Institute January 14, 2003

2 2 Outline Definitions of Architecture Architectural Styles Patterns

3 3 Definitions of Architecture (1) 1. The art and science of designing and erecting buildings. 2. Buildings and other large structures: “the low, brick-and-adobe architecture of the Southwest.” American Heritage® Dictionary of the English Language: Fourth Edition. 2000.

4 4 Definitions of Architecture (2) 3. A style and method of design and construction: “Byzantine architecture.” 4. Orderly arrangement of parts; structure: “the architecture of the federal bureaucracy; the architecture of a novel.” American Heritage® Dictionary of the English Language: Fourth Edition. 2000.

5 5 Definitions of Architecture (3) 5. Computer Science The overall design or structure of a computer system, including the hardware and the software required to run it, especially the internal structure of the microprocessor. American Heritage® Dictionary of the English Language: Fourth Edition. 2000.

6 6 Software Architecture Global control Communication, synchronization and data access Assignment of functionality to design elements Composition of design elements Scaling and performance

7 7 Outline Definitions of Architecture Architectural Styles Patterns

8 8 Architectural Styles (1) Dataflow Batch sequential Pipes and filters Call-and-return Main program and subroutine OO systems Hierarchical layers

9 9 Architectural Styles (2) Independent components Communicating processes Event systems Virtual machines Interpreters Rule-based systems

10 10 Architectural Styles (3) Data-centered Databases Hypertext systems Blackboards

11 11 Blackboard Architecture Knowledge sources separate and independent Blackboard data structure problem-solving state knowledge sources update it Control driven by state of blackboard

12 12 Blackboard Example Blackboard (shared data) ks1ks2ks3ks4ks5 ks6 ks7

13 13 Pipe and Filter Architecture Filters Pipes

14 14 Examples of Pipe-and-Filter Unix shell scripts Compilers lexical analysis, parsing, semantic analysis, code generation Batch sequential degenerate case where all input processed before any output

15 15 Layered Architecture Core Utilities Applications

16 16 Interpreter Architecture Interpreter Engine Program DataOutput

17 17 Architecture Review Boards Review Architectural Specifications Provide shared knowledge across projects Prevent mistakes early

18 18 First Cartoon of the Day

19 19 Outline Definitions of Architecture Architectural Styles Patterns

20 20 Christopher Alexander Architect who proposed that people design their own dwellings, using accepted patterns of design Wrote a series of books that influenced the OO community

21 21 A Place to Wait (1/3) The process of waiting has inherent conflicts in it. On the one hand, whatever people are waiting for---the doctor, an airplane--- has built-in uncertainties, which make it inevitable that they must spend a long time hanging around, waiting, doing nothing.

22 22 A Place to Wait (2/3) On the other hand, they cannot usually afford to enjoy this time. Since they never know when their turn will come, they cannot even take a stroll or sit outside.

23 23 A Place to Wait (3/3) Therefore: In places where people end up waiting, create a situation which makes the waiting positive. Fuse the waiting with some other activity--- newspaper, coffee, pool tables; something which draws people in who are not simply waiting. And also the opposite: make a place which can draw a person waiting into a reverie; quiet; a positive silence.

24 24 History of Software Patterns Kent Beck had read Alexander's work while in college Kent convinced Ward Cunningham that ideas were good They helped a group design a user interface by letting users design it (1987)

25 25 Beck and Cunningham's Original Patterns Window Per Task Few Panes Standard Panes Nouns and Verbs Short Menus

26 26 Window Per Task Make a specific window for each task the user must perform. All of the information needed to complete a task should be available in the Few Panes of the window. Assume prerequisite tasks have been completed (if they haven't, the user will simply change windows).

27 27 Few Panes To understand complex things one often must see it from several points of view. Therefore: Provide these points of view by dividing the area of your Window Per Task into panes.

28 28 Standard Panes One must learn to operate each kind of pane offered in the Few Panes of every window. Therefore: Cast each pane into the format offered by one of a few standard panes. [Tektronix had 4.]

29 29 Nouns and Verbs Things exist while action happens. Therefore: Put lists of things (nouns) in a list pane (one of Few Panes) which persists through interactions. Put actions (verbs) in Short Menus which pop up and then disappear as the action commences.

30 30 Short Menus The elements of a pop-up menu must be visually searched repeatedly. Therefore: Make them short, fixed and single-level.

31 31 What is a Pattern? "a named nugget of insight that conveys the essence of a proven solution to a recurring problem within a certain context amidst competing concerns" "a solution to a problem in a context"

32 32 Pattern Parts Name Problem description Context: when is it applicable? Forces: what are the tradeoffs? Solution Consequences...

33 33 A Good Pattern solves a problem is a proven concept describes a relationship has a significant human component provides a solution that isn't obvious

34 34 Qualities of a Pattern Encapsulation and abstraction Openness and variability Generativity and composability Equilibrium

35 35 Leaky Bucket Counters (1/2) Problem: How do you deal with transient faults? Context: Fault-tolerant software that must deal with failure events. Forces: You want a hardware module to exhibit hard failures before taking drastic action. Some failures come from the environment, and should not be blamed on the device.

36 36 Leaky Bucket Counters (2/2) Solution: A failure group has a counter that is incremented for each failure. Each counter is decremented periodically. A hard failure is not reported until the counter exceeds a threshold. Consequences: Hard errors are handled, but transient errors are not as likely to trigger error handling.

37 37 Second Cartoon of the Day

38 38 Writers' Workshops Method of publishing patterns Process: 1. Author reads a short segment 2. Others provide constructive criticism while author remains silent 3. Group thanks author (applause)

39 39 Pattern Mining Interview experts about their domain Record patterns that are found Share resulting set with experts

40 40 Advantages of Patterns Shorten discovery Avoid inexpert design decisions Reuse large chunks of design

41 41 References Gamma, Helm, Johnson and Vlissides Design Patterns, Addison-Wesley 1995, ISBN 0-201-63361-2. (Gang of Four) Jim Coplien, Software Patterns Management Briefing, 1996, http://www.bell-labs.com/ user/cope/Patterns/WhitePaper Appleton, Brad Patterns and Software: Essential Concepts and Terminology, 2000 http://www.cmcrossroads.com/ bradapp/docs/patterns-intro.html

42 42 Books by Alexander Notes on the Synthesis of Form, Harvard University Press, 1964 The Oregon Experiment, Oxford University Press, 1975 A Pattern Language: Towns, Buildings, Construction, Oxford University Press, 1977 The Timeless Way of Building, Oxford University Press, 1979


Download ppt "1 Software Architecture CS 414, Software Engineering I Mark Ardis, Rose-Hulman Institute January 14, 2003."

Similar presentations


Ads by Google