1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational...

32
1 Chapter 14 Chapter 14 Architectural Architectural Design Design

Transcript of 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational...

Page 1: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

1

Chapter 14Chapter 14Architectural Architectural

DesignDesign

Page 2: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

2

Why Why Architecture?Architecture?

The architecture is not the operational The architecture is not the operational software. Rather, it is a representation that software. Rather, it is a representation that enables a software engineer to: enables a software engineer to:

(1) analyze the effectiveness of the design in (1) analyze the effectiveness of the design in meeting its stated requirements, meeting its stated requirements,

(2) consider architectural alternatives at a (2) consider architectural alternatives at a stage when making design changes is still stage when making design changes is still relatively easy, and relatively easy, and

(3) reduce the risks associated with the (3) reduce the risks associated with the construction of the software.construction of the software.

Page 3: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

3

Data Data DesignDesign refine data objects and develop a refine data objects and develop a

set of data abstractionsset of data abstractions implement data object attributes implement data object attributes

as one or more data structuresas one or more data structures review data structures to ensure review data structures to ensure

that appropriate relationships that appropriate relationships have been establishedhave been established

simplify data structures as simplify data structures as requiredrequired

Page 4: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

4

Data Design—Component Data Design—Component LevelLevel1. The systematic analysis principles applied

to function and behavior should also be applied to data. 2. All data structures and the operations to be performed on each should be identified. 3. A data dictionary should be established and used to define both data and program design. 4. Low level data design decisions should be deferred until late in the design process.

Page 5: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

5

Data Design—Component Data Design—Component LevelLevel5. The representation of data structure should

be known only to those modules that must make direct use of the data contained within the structure. 6. A library of useful data structures and the operations that may be applied to them should be developed. 7. A software design and programming language should support the specification and realization of abstract data types.

Page 6: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

6

Architectural Architectural StylesStylesEach style describes a category encompassing:

(1) set of components (e.g., a database, computational modules) that performs a system function

2) set of connectors enabling communication, and coordination among components,

(3) constraints that define how components can be integrated to form the system, and

(4) semantic models that enable a designer to understand overall properties of a system by analyzing properties of its constituent parts.

Page 7: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

7

Architectural Architectural StylesStyles

Data-centered architecturesData-centered architectures Data flow architecturesData flow architectures Call and return Call and return

architecturesarchitectures Object-oriented Object-oriented

architecturesarchitectures Layered architecturesLayered architectures

Page 8: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

8

Data-Centered Data-Centered ArchitectureArchitecture

Page 9: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

9

Data Flow Data Flow ArchitectureArchitecture

Page 10: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

10

Call and Return Call and Return ArchitectureArchitecture

Page 11: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

11

Layered Layered ArchitectureArchitecture

Page 12: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

12

Analyzing Architectural Analyzing Architectural DesignDesign

1. Collect scenarios. 1. Collect scenarios. 2. Elicit requirements, constraints, and 2. Elicit requirements, constraints, and environment description. environment description. 3. Describe the architectural styles/patterns 3. Describe the architectural styles/patterns that have been chosen to address the that have been chosen to address the scenarios and requirements:scenarios and requirements:

• • module viewmodule view• • process viewprocess view• • data flow viewdata flow view

Page 13: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

13

Analyzing Architectural Analyzing Architectural DesignDesign

4. Evaluate quality attributes by considered 4. Evaluate quality attributes by considered each attribute in isolation. each attribute in isolation. 5. Identify the sensitivity of quality attributes 5. Identify the sensitivity of quality attributes to various architectural attributes for a to various architectural attributes for a specific architectural style. specific architectural style. 6. Critique candidate architectures 6. Critique candidate architectures (developed in step 3) using the sensitivity (developed in step 3) using the sensitivity analysis conducted in step 5.analysis conducted in step 5.

Page 14: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

14

An Architectural Design An Architectural Design MethodMethod

"four bedrooms, three baths,lots of glass ..."

customer requirements

architectural design

Page 15: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

15

Deriving Program Deriving Program ArchitectureArchitecture

ProgramProgramArchitectureArchitecture

Page 16: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

16

Why Partitioned Why Partitioned Architecture?Architecture?

results in software that is easier to testresults in software that is easier to test leads to software that is easier to leads to software that is easier to

maintainmaintain results in propagation of fewer side results in propagation of fewer side

effectseffects results in software that is easier to results in software that is easier to

extendextend

Page 17: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

17

Structured DesignStructured Design

objective:objective: to derive a program to derive a program architecture that is partitionedarchitecture that is partitioned

approach:approach: the DFD is mapped into a program the DFD is mapped into a program

architecturearchitecturethe PSPEC and STD are used to indicate the PSPEC and STD are used to indicate

the content of each modulethe content of each module

notation:notation: structure chart structure chart

Page 18: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

18

General Mapping General Mapping ApproachApproachisolate incoming and outgoing flow isolate incoming and outgoing flow

boundaries; for transaction flows, isolate boundaries; for transaction flows, isolate the transaction centerthe transaction center

working from the boundary outward, mapworking from the boundary outward, mapDFD transforms into corresponding modulesDFD transforms into corresponding modules

add control modules as requiredadd control modules as required

refine the resultant program structurerefine the resultant program structureusing effective modularity conceptsusing effective modularity concepts

Page 19: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

19

Transform Transform MappingMapping

data flow model

"Transform" mapping

ab

c

d e fg h

ij

x1

x2 x3 x4

b c

a

d e f g i

h j

Page 20: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

20

First Level First Level FactoringFactoring

main programcontroller

inputcontroller

processingcontroller

outputcontroller

Page 21: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

21

Transaction Transaction FlowFlow

T

incoming flow

action path

Page 22: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

22

Transaction Transaction ExampleExample

operatorcommands

processoperator commands

fixture setting

report

robot control

fixtureservos

displayscreen

robotcontrolsoftware

in reality, other commandswould also be shown

assemblyrecord

Page 23: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

23

Refining the Analysis Refining the Analysis ModelModelwrite an English language processing narrative write an English language processing narrative

for the level 01 flow modelfor the level 01 flow model

apply noun/verb parse to isolate processes, data apply noun/verb parse to isolate processes, data items, store and entitiesitems, store and entities

develop level 02 and 03 flow modelsdevelop level 02 and 03 flow models

create corresponding data dictionary entriescreate corresponding data dictionary entries

refine flow models as appropriaterefine flow models as appropriate

... now, we're ready to begin design!... now, we're ready to begin design!

1.1.

2.2.

3.3.

4.4.

5.5. censored

censored

Page 24: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

24

Deriving Deriving Level 1Level 1Processing narrative for " process operator commands"

Process operator command software reads operator commands from the cell operator. An error message is displayed for invalid commands. The command type is determined for valid commands and appropriate action is taken. When fixture commands are encountered, fixture status is analyzed and a fixture setting is output to the fixture servos. When a report is selected, the assembly record file is read and a report is generated and displayed on the operator display screen. When robot control switches are selected, control values are sent to the robot control system.

Processing narrative for " process operator commands"

Process operator command software reads operator commands from the cell operator. An error message is displayed for invalid commands. The command type is determined for valid commands and appropriate action is taken. When fixture commands are encountered, fixture status is analyzed and a fixture setting is output to the fixture servos. When a report is selected, the assembly record file is read and a report is generated and displayed on the operator display screen. When robot control switches are selected, control values are sent to the robot control system.

noun-verbparse

censored

censored

Page 25: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

25

Level 1 Data Flow DiagramLevel 1 Data Flow Diagram

operator commands

read operator

commands

determine command

type

analyze fixture status

generate report

send control value

fixture servos

display screen

robot control system

assembly record

valid command

Error msg

fixture setting

robot control

fixture

select report

control robot

status

assembly

report

status

censored

censored

Page 26: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

26

Level 2 Data Flow Level 2 Data Flow DiagramDiagram

read command

produce error msg

validate command

determine type

read fixture status

determine setting

format setting

read record

calculate output values

format report

reportvalues

record

assembly record

command

command invalid command

status

error msg

robot control

send control value

start /stop

combined status

raw setting

fixture setting

censored

censored

Page 27: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

27

Transaction Mapping Transaction Mapping PrinciplesPrinciples

isolate the incoming flow pathisolate the incoming flow path

define each of the action paths by looking for define each of the action paths by looking for the "spokes of the wheel"the "spokes of the wheel"

assess the flow on each action pathassess the flow on each action path

define the dispatch and control structuredefine the dispatch and control structure

map each action path flow individuallymap each action path flow individuallycensored

censored

Page 28: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

28

Transaction Transaction MappingMapping

data flow model

ab

t

de f

gh

i

j

kl

mn Mapping

b

a

x1

t

x2

d e f

x3

g h x3.1

i j

k

x4

l m ncensored

censored

Page 29: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

29

Isolate Flow Isolate Flow PathsPaths

read command

produce error msg

validate command

determine type

read fixture status

determine setting

format setting

read record

calculate output values

format report

reportvalues

record

assembly record

command

command invalid command

status

error msg

robot control

send control value

start /stop

combined status

raw setting

fixture setting

censored

censored

Page 30: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

30

Map the Flow Map the Flow ModelModel

process operator

commands

command input

controller

read command

validate command

produce error

message

determine type

fixture status

controller

report generation controller

send control value

each of the action paths must be expanded furthercensored

censored

Page 31: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

31

Refining the Structure Refining the Structure ChartChartprocess operator

commands

command input

controller

read command

validate command

produce error

message

determine type

send control value

read fixture status

determine setting

format setting

read record

calculate output values

format report

fixture status

controller

report generation controller

censored

censored

Page 32: 1 Chapter 14 Architectural Design. 2 Why Architecture? The architecture is not the operational software. Rather, it is a representation that enables a.

32

Interface Are Interface Are DesignedDesigned

intermodular interface designintermodular interface designdriven by data flow between modulesdriven by data flow between modules

external interface designexternal interface designdriven by interface between applicationsdriven by interface between applicationsdriven by interface between software and non-driven by interface between software and non-

human producers and/or consumers of human producers and/or consumers of informationinformation

human-computer interface designhuman-computer interface designdriven by the communication between human driven by the communication between human

and machineand machine