1. MedTech
Chapter 5 – Software Architecture
How to define the architecture of your software product
Dr. Lilia SFAXI
www.liliasfaxi.wix.com/liliasfaxi
Slide 1
MedTech – Mediterranean Institute of Technology
CS321-Software Engineering
MedTech
3. MedTech
Software Architecture
• Architecture
• « 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. » [ANSI/IEEE Std 1471-2000]
• Software Architecture
• « The software architecture of a program or computing system is the
structure or structures of the system, which comprise software elements,
the externally visible properties of those elements, and the relationships
among them. »[SEI]
Dr. Lilia SFAXI
www.liliasfaxi.wix.com/liliasfaxi
Slide 3
Software Architecture - Definition
4. MedTech
Software Architecture
• Mainly: Architecture Defines Structure
• Decomposition of system into :
• Software Elements
• Elements are captured as abstractions
• Correspond to high level system modules or components
• Component interfaces
• External visible properties of elements
• Describe element features exposed to others
• Typically represent services provided to other elements
• Component responsibilities
• What does a component precisely do?
• Relationships of elements
• How do elements interact with others?
Dr. Lilia SFAXI
www.liliasfaxi.wix.com/liliasfaxi
Slide 4
Software Architecture - Definition
5. MedTech
Software Architecture Structures Examples
Dr. Lilia SFAXI
www.liliasfaxi.wix.com/liliasfaxi
Slide 5
Software Architecture - Definition
Modules Components and Connections
7. MedTech
Structures from Multiple Views
Dr. Lilia SFAXI
www.liliasfaxi.wix.com/liliasfaxi
Slide 7
Software Architecture - Definition
• Large software systems require structures from multiple perspectives
(views)
• A single view is not sufficient to address all the requirements
• Examples of views
• Context View
• Focuses on the system’s functionality
• Deployment View
• Reflects the physical deployment of software components to computing
hardware
8. MedTech
Analogy : Building Architecture Views
Dr. Lilia SFAXI
www.liliasfaxi.wix.com/liliasfaxi
Slide 8
Software Architecture - Definition
2D Front View
Floor Plan View
Room Plan View
9. MedTech
Why Using Software Architecture?
• Crucial changes in software engineering
have increased the importance of
architecture
• Scale
• Distribution
• Security
Dr. Lilia SFAXI
www.liliasfaxi.wix.com/liliasfaxi
Slide 9
Software Architecture - Definition
Minimally Distributed System
Highly Distributed System
10. MedTech
A Good Software Architecture…
• Considers for the system:
• The functional requirements
• The non functional requirements
• The entire system lifecycle
• Helps us understand the system:
• Divides the system meaningfully
• Abstract complicated details
• Provides the framework for:
• Realization
• Project Planning
• Project Organization
• Integrate all the development artefacts
• Provide documentation
Dr. Lilia SFAXI
www.liliasfaxi.wix.com/liliasfaxi
Slide 10
Software Architecture - Definition
11. MedTech
Software Architect
The ideal Software Architect should be a man of letters, a
mathematician, familiar with historical studies, a dilifent
student of philosophy, acquainted with music, not ignorant of
medicine, learned in the responses of juriconsults, familiar with
astronomy and astronomical calculations.
Vitrivus (Roman author, architect and civil engineer, during the 1st century BC)
Dr. Lilia SFAXI
www.liliasfaxi.wix.com/liliasfaxi
Slide 11
Software Architecture - Definition
12. MedTech
Software Architect and Others
Dr. Lilia SFAXI
www.liliasfaxi.wix.com/liliasfaxi
Slide 12
Software Architecture - Definition
14. MedTech
Architectural Patterns
• An architectural pattern in a proven structural organization schema for
software systems
• Architectural Patterns vs Design Patterns (already seen in chapter 4)
• Design Patterns offer a common solution for a common problem in the form
of classes working together
• Smaller in scale than architectural patterns, where the components are
subsystems rather than classes
• Design Patterns do not influence the fundamental structure of a system
• Only affect a single subsystem
• They may help implementing an architectural pattern
• Some (not all) architectural patterns are described here-after
Dr. Lilia SFAXI
www.liliasfaxi.wix.com/liliasfaxi
Slide 14
Software Architecture Patterns
15. MedTech
Pattern 1: Layers Pattern
• Helps structure applications that can be decomposed into groups of
subtasks, each of which is at a particular level of abstraction
• Each layer provides services to the next higher layer
• Services in a layer are implemented using services from the next lower
layer
• Service requests are frequently done by using synchronus procedure
calls
• Most famous example of layered systems: networking protocols
Dr. Lilia SFAXI
www.liliasfaxi.wix.com/liliasfaxi
Slide 15
Software Architecture Patterns
18. MedTech
Pattern 2: Client-Server Pattern
• A server component provides services to multiple client components
• A client component requests services from the server component
• Servers are permanently active, listening for clients
• Client and server may reside in different machines
• This pattern can be considered as a form of the layered pattern with
two layers, the clients being the higher level and the server the lower
level
• Examples
• Remote database access
• Remote file systems access
• Web-based applications (browsers request from a web server)
Dr. Lilia SFAXI
www.liliasfaxi.wix.com/liliasfaxi
Slide 18
Software Architecture Patterns
20. MedTech
Pattern 3: Master-Slave Pattern
• Supports fault-tolerance and parallel computation
• The master component distributes the work among identical slave
components, and computes a final result from the results they return
• Applied for instance in :
• Process control
• Embedded systems
• Large scale parallel computations
• Fault-tolerant systems
Dr. Lilia SFAXI
www.liliasfaxi.wix.com/liliasfaxi
Slide 20
Software Architecture Patterns
22. MedTech
Pattern 4: Pipe-Filter Pattern
• Provides a structure for systems that produce a stream of data
• Each processing step is encapsulated in a filter component
• Data is passed through pipes
• Pipes can be used for buffering or for synchronization
• This pattern divides the task of a system into several processing steps
• The steps are connected by the data flow
• The output of a step is the input for the next step
• Common examples:
• Pipe-filter in the unix shell commands
• cat file | grep xyz | sort | uniq > out
• Compilers
Dr. Lilia SFAXI
www.liliasfaxi.wix.com/liliasfaxi
Slide 22
Software Architecture Patterns
24. MedTech
Pattern 5: MVC Pattern
• Model-View-Controller Pattern
• An interactive application is divided into three parts:
• Model
• Contains core fundtionality and data
• View
• Displays the information to the user
• Controller
• Handles the input from the user
• Often uses the Observer design pattern
• User input can invoke a change in the model, and in the displayed view
• Makes it easy to have multiple views of the same model
Dr. Lilia SFAXI
www.liliasfaxi.wix.com/liliasfaxi
Slide 24
Software Architecture Patterns