Software Architecture and Design
Software Architecture and Design
design
What is Software Architecture
Definitions
3
Architecture defined
Formal Definition
• IEEE 1471-2000
– Software architecture is the fundamental organization
of a system, embodied in its components, their
relationships to each other and the environment, and the
principles governing its design and evolution.
Architecture defined
non-functional architecture
requirements
functional
requirements design
• Performance
• Availability Time To Market
• Usability Cost and Benefits
End User’s view Projected life Business
• Security
time Community
view
Targeted Market
Integration with
Maintainability
Legacy System
Portability Roll back
Reusability Developer’s view Schedule
Testability
Architecture Programs
interactions among parts implementations of parts
structural properties computational properties
declarative operational
mostly static mostly dynamic
system-level performance algorithmic performance
outside module boundary inside module boundary
composition of subsystems copy code or call libraries
Promised Benefits of
Architectural Modeling
Promised Benefits of
Architectural Modeling
Architecture
Reduce maintenance
costs, directly and
Code/Integ
• Clarify intentions indirectly
• Make decisions and Test/Accept
implications explicit
• Permit system-level
analysis Maintenance
Architectural Design Reviews
Architectural Design Reviews
Requirements
Discovery
Review Architecture
High-Level
Design
Source:
Joe Maranzano
ATT Bell Labs Architecture Low-Level
Review Design
Architectural Structure:
Components, Connectors,
Systems
Architectural Structure:
Components, Connectors, Systems
• Components
– computational elements
• Ports
– interface points for components
• Connectors
– interactions between components
• Roles
– interface points for connectors
• Systems
– graphs of component and connectors
Architectural Design Process
Architectural Design Process
• System structuring
– system decomposed into several subsystems
– subsystem communication is established
• Control modeling
– model of control relationships among system components
is established
• Modular decomposition
– identified subsystems decomposed into modules
Architectural Models
Architectural Models
Design Report
analyser generator
Call-Return Model
Main
program
Sensor Actuator
processes processes
System
contr oller
Interrupt
vector
Symbol
table
6 Presentation Presentation
5 Session Session
4 Transport Transport
Sensor Light
Display control
control process
process process
Traffic lights
Traffic flow sensors
and cameras Operator consoles
Client/Server Architectures
Client/Server Architectures
c2 c3 c4 c12
c11
Server process
c1
s1 s4
c10
c5
Client process
s2 s3 c9
c6 c8
c7
Representative Client/Server
Systems
• File servers
– client requests selected records from a file
– server transmits records to client over the network
• Database servers
– client sends SQL requests to server
– server processes the request
– server returns the results to the client over the network
Representative Client/Server
Systems
• Transaction servers
– client sends requests that invokes remote procedures on
the server side
– server executes procedures invoked and returns the
results to the client
• Groupware servers
– server provides set of applications that enable
communication among clients using text, images, bulletin
boards, video, etc.
Client/Server Software
Components
Client/Server Software
Components
• User interaction/presentation subsystem
• Application subsystem
– implements requirements defined by the application within
the context of the operating environment
– components may reside on either client or server side
• Database management subsystem
• Middleware
– all software components that exist on both the client and
the server to allow exchange of information
Thin Client Model
Thin Client Model
Client
Client
Design Issues for Client/Server
Systems
Design Issues for
Client/Server Systems
• Data and architectural design
– dominates the design process to be able to effectively
use the capabilities of RDBMS or OODMBS
• Event-driven paradigm
– when used, behavioral modeling should be conducted
– the control-oriented aspects of the behavioral model
should translated into the design model
Design Issues for
Client/Server Systems
• Interface design
– elevated in importance
– user interaction/presentation component implements all
functions associated with a GUI
• Object-oriented point of view
– often chosen, since object structure is provided by
events initiated in the GUI and their event handlers
within the client-based software
Distributed Object Architectures
Distributed Object
Architectures
• No distinctions made between client objects and
server objects
• Each distributable entity is an object that both
provides and consumes services
• Object communication is though an object request
broker (middleware or software bus)
• More complex to design than client/server systems
Distributed Object Architecture
from Sommerville
o1 o2 o3 o4
Software bus
o5 o6
S (o5) S (o6)
Architectural Design Process
Architectural Design Process
• Basic Steps
– Creation of the data design
– Derivation of one or more representations of the architectural
structure of the system
– Analysis of alternative architectural styles to choose the one best
suited to customer requirements and quality attributes
– Elaboration of the architecture based on the selected architectural
style
• A database designer creates the data architecture for a
system to represent the data components
• A system architect selects an appropriate architectural
style derived during system engineering and software
requirements analysis
69
Emphasis on Software
Components
71
A Taxonomy of Architectural Styles
Independent Components
Implicit Explicit
Client/Server Peer-to-Peer
Invocation Invocation
73
Data Flow Style
• Batch sequential style
– The processing steps are independent components
– Each step runs to completion before the next step
begins
• Pipe-and-filter style
– Emphasizes the incremental transformation of data
by successive components
– The filters incrementally transform the data (entering
and exiting via streams)
– The filters use little contextual information and retain
no state between instantiations
– The pipes are stateless and simply exist to move
data between filters
74
Data Flow Style (continued)
75
Call-and-Return Style
Main module
Subroutine B
Subroutine A
Transport layer
Data layer
Class Z
76
Physical layer
Call-and-Return Style
77
Remote procedure call style
79
Call-and-Return Style
Layered system
Shared Data
81
Data-Centered Style (continued)
83
Virtual Machine Style
Program
Program Data
Instructions
Interpretation Program
Engine Internal State
84
Virtual Machine Style
85
Virtual Machine Style
Server
Client C Client D
Peer W Peer X
Peer Y Peer Z
87
Independent Component Style
88
Independent Component Style
90
Independent Component Style
• Business Architecture
• Technical Architecture
• Solutions Architecture
• Enterprise Architecture
• Product Line Architecture
Business Architecture
• Evolutionary
– Product line architecture and components evolve
with the requirements posed by new product line
members.
• Revolutionary
• Product line architecture and components developed to
match requirements of all expected product-line
members
Architectural Analysis in a
Nutshell
101
Software Architecture: Foundations, Theory, and Practice; Richard N. Taylor, Nenad Medvidovic, and Eric M. Dashofy; © 2008 John Wiley & Sons, Inc. Reprinted with permission.
References and Bibliography