SlideShare a Scribd company logo
1 of 106
Dharmalingam Ganesan
Software Architecture – Insights
from Practice
2
What’s On The Agenda
â—Ź Software Architecture
â—Ź Introduction and Motivation
â—Ź Architecture vs. Design
â—Ź Software Connectors
â—Ź Software Architectural Styles
â—Ź Introduction and Motivation
â—Ź Types of Styles
â—Ź Software Architecture Description
â—Ź Introduction and Motivation
â—Ź Viewpoints, Views,
â—Ź Consistency across Views
â—Ź Architectural Perspectives and Quality
â—Ź Software Architecture for Product Lines
â—Ź Introduction and Motivation
â—Ź Architecting for Variability and Commonality
3
Software Architecture
â—Ź Software architecture deals with the design of the high-
level structure of the software
â—Ź Assembly of architectural elements in some well-chosen
forms to satisfy requirements (including Reliability,
Scalability, Portability, etc)
â—Ź Software architecture = {Elements, Forms,
Rationale/Constraints}
â—Ź Software architecture deals with
â—Ź abstraction
â—Ź decomposition and composition
â—Ź styles
4
Architecture of Core Flight software
4
(BSP)
5
Why we need Software Architecture?
â—Ź Real-world systems are large and complex
â—Ź Need to divide-and-conquer
â—Ź Software architecture is used for:
â—Ź Distributing work to teams for developing components
(in parallel)
â—Ź Integrating components
â—Ź Planning and defining strategies for software testing
● Understanding the “big-picture” of the system
â—Ź Software architecture is for Project
Managers, Developers, Testers, Customers
(details next slides)
6
Use of Software Architecture for
Project Managers
â—Ź Managing large projects is a challenging task
â—Ź Software architecture can help managers through divide-
and-conquer strategy
â—Ź Project managers can use Software Architecture for:
â—Ź Assigning budget and effort for components
â—Ź Coordinating with architects, developers, testers, etc
â—Ź Assigning people with the right skills to the right components
(e.g., people with device-driver skills to Hardware/OS intensive
components)
â—Ź Tracking the project progress based on individual components
â—Ź Developing a business model or marketing strategy (e.g., selling a
part of the system, Open Source, Outsourcing)
7
Use of Software Architecture for
Developers and Testers
â—Ź Developers should implement individual
components based on Software Architecture
â—Ź Developers need to understand Software
Architecture before making changes to
existing implementation
â—Ź Testers have to define test-strategy based on
Software Architecture, for example:
â—Ź Should low-level components be tested first,
high-level components be tested first, or a mix
â—Ź Testers may have to write mock-test or stubs
to unit-test individual components
8
Use of Software Architecture for
System Builders
â—Ź Software Arch. is needed to compile, link, and
produce executables
â—Ź Developing Makefiles or build scripts requires
sound understanding of your architecture
â—Ź You can even generate Makefiles (or build
scripts) for each directory if you know your arch.
â—Ź Dependency rules are needed to compile the right
set of files when source code evolves
9
Architecture vs. (detailed) Design
â—Ź Difference lies in your context and how you see
â—Ź An architectural diagram in one context could
become a design diagram in another context
â—Ź For example:
â—Ź if you architect a component you may develop
architectural diagrams for it
â—Ź if the same component is used in another system,
then those arch diagrams become design diagrams
10
Architecture vs. (detailed) Design
â—Ź Architecture is concerned with global decisions
â—Ź Design is concerned with local decisions
â—Ź That is, architecture is concerned with the system-level
design decisions
â—Ź How components fit-together?
â—Ź What are the interfaces?
â—Ź System-level performance, scalability, security, etc.,
â—Ź Whereas design is concerned with sub-parts of the system
â—Ź How components are designed internally?
â—Ź Which algorithms to choose?
11
Software Connectors
â—ŹConnectors, for example:
â—ŹProcedure Call
â—ŹFile
â—ŹPipe
â—ŹQueue
â—ŹSocket
â—ŹShared Memory
â—ŹConnectors are used for connecting
components
12
Components vs. Connectors
â—ŹComponents provide application
functionality
â—Ź Connectors specify the protocol of
interaction among components
â—Ź Connectors are usually independent of
the application domain
â—Ź Connectors are often implemented by
programming languages or OS
13
(Some) Main Roles of Connectors
â—Ź Coordinator
â—Ź Wrapper
â—Ź Adaptor
â—Ź Monitor
14
Coordinator as a Connector
â—Ź Let us assume we want to draw a bar chart for
some stock data
â—Ź Also assume we have two components:
● CollectStockData – collects stock data to a file
● DisplayStockData – draws a graph based on the file
â—Ź How do we compose these two components?
â—Ź We need a coordinator that invokes:
1. CollectData
2. DisplayData
Coordinator as a Connector …
void collectStockData(File outputFile, …) {
/* Connect to the Stock Server */
…
/* Write stock data to the output file */
outputFile.write(…);
}
void displayStockData(File inputFile, …) {
/* Extract data from inputFile */
dataSet = readLines(inputFile)
…
/* Draw chart using dataSet */
…
ui.drawBarChart(dataSet);
}
void my_main() {
/* Collect stock data to a file */
collectStockData(dataFile);
/* Display the stock data */
displayStockData(dataFile);
}
coordinator
16
Wrapper as a Connector
â—Ź Let us assume we want to log the important
events of the system
● Apache’s Log4j is a popular library for logging
â—Ź If components of the system use Log4j directly,
there are a few problems:
â—Ź Not easy to replace Log4j by another library
â—Ź Possibly the layouts of log are different (hard to
analyze)
â—Ź Solution: Develop a wrapper to Log4j
â—Ź This wrapper acts as a connector to the Log4j
library
Wrapper as a Connector …
…
import org.apache.log4j.ConsoleAppender;
import org.apache.log4j.Level;
import org.apache.log4j.Logger;
import org.apache.log4j.EnhancedPatternLayout;
…
/**
* This class provides common logger wrapper to facilitate the customized usage
* of Apache log4j logger.
*/
public class LogService
{
// For current instance (singleton)
private static LogService instance = null;
// Log4j logger
private static Logger logger = null;
…
Wrapper
18
Adaptor as a Connector
â—Ź Adaptors are often used to handle mismatches in
interfaces of components
â—Ź Enables interaction of independently developed
mismatched components
â—Ź For example:
â—Ź Let Component A writes data to a pipe
â—Ź But Component B can read data only from a file
â—Ź How can we put A and B to work together?
â—Ź Solution: We need a Connector C that reads data
from the pipe (until EOF) and write to the file
from which B can read
Adaptor as a Connector …
void collectStockData(PipedWriter pw, …) {
/* Connect to the Stock Server */
…
/* Write stock data to the pipe */
pw.write(…);
}
void displayStockData(File inputFile, …) {
/* Extract data from inputFile */
dataSet = readLines(inputFile)
…
/* Draw chart using dataSet */
…
ui.drawBarChart(dataSet);
}
void my_adaptor() {
/* Collect stock data to a file */
PipedReader pr;
PipedWriter pw;
pw.connect(pr);
collectStockData(pw);
/* read from the pipe and write to a file*/
File dataFile = writeToFile(pr);
/* Display the stock data */
displayStockData(dataFile); …
Adaptor
20
Monitor as a Connector
â—Ź In practice, connectors are also used to monitor
the running system
â—Ź For example:
â—Ź all data written to a socket connector is logged by
the write method
â—Ź Counts number of write and read calls
â—Ź Time of write and read
â—Ź This data can be used by the
architects/developers for understanding the real-
traffic and improve system performance
â—Ź Run-time load balancing
21
What’s On The Agenda
â—Ź Software Architecture
â—Ź Introduction and Motivation
â—Ź Architecture vs. Design
â—Ź Software Connectors
â—Ź Software Architectural Styles
â—Ź Introduction and Motivation
â—Ź Types of Styles
â—Ź Software Architecture Description
â—Ź Introduction and Motivation
â—Ź Viewpoints, Views,
â—Ź Consistency across Views
â—Ź Architectural Perspectives and Quality
â—Ź Software Architecture for Product Lines
â—Ź Introduction and Motivation
â—Ź Architecting for Variability and Commonality
22
Architecture Style of Historical
Buildings – Some Examples
â—Ź Dravidian Architecture characteristics:
â—Ź pyramidal towers of colossal height dominating the
surrounding landscape for miles around
â—Ź the rectangular enclosures one within the other
â—Ź the use of the flat roof and the entire absence of the
arch or dome;
â—Ź dependent on intricate carved stone
23
Families of Dravidian Architecture
24
Composition and Structure of
Dravidian Temples
1. The principal part, the actual temple itself, is called
the Vimana. It is always square in plan, and
surmounted by a pyramidal roof of one or more
stories; and it contains the cell in which the image of
the god or his emblem is placed.
2. The porches, which always cover and precede the
door leading to the cell.
3. Gate-pyramids , which are the principal features in
the quadrangular enclosures that surround the
more notable temples.
4. Pillared halls -- used for various purposes, and
which are the invariable accompaniments of these
temples.
25
Mughal Architecture Style – Taj
Mahal
â—Ź the architectural design of Taj Mahal uses the
interlocking arabesque concept:
â—Ź each element is complete in itself, yet it integrates
perfectly to look as though it is a part of the main
structure.
â—Ź The corners of the platform are truncated to form
an unequal octagon.
â—Ź Self-replicating symmetry and geometry of
architectural elements are the ruling principles in
the design of Taj.
26
Families of Mughal Architecture Style
27
Families of Gothic Architecture
28
Architectural Styles - Benefits
â—Ź Explains the nature of components used
â—Ź Explains the topology
â—Ź way the system (e.g., building) is structured
â—Ź Help to build a family of systems
➢Let us learn about Software Architecture Styles
29
Some Software Architectural Styles
â—Ź Layer
â—Ź Pipe-and-Filter
â—Ź Publish-Subscribe
â—Ź Implicit-Invocation
â—Ź Styles for Net-Centric Systems
â—Ź Client-Server
â—Ź Peer-to-Peer
30
Layered Style
â—Ź The system is organized as a collection of layers
based on abstraction levels
â—Ź Typically, Components of the lowest-level layer
interacts with the underlying OS or Hardware
â—Ź Topology: A Layer uses services offered by its
adjacent low-level layer (via API)
â—Ź (Static) Control-flow is from the top layer to the
bottom layer
â—Ź At run-time, due to callbacks the control can flow
from the bottom layer to the top layer
31
Layered Style - Benefits
â—Ź Enables incremental testing from the bottom to
top layer
â—Ź Plug-out and Plug-in of a layer with a new layer
conforming to the same API
â—Ź Helpful in producing variants of a product
â—Ź Helps to distribute the work to different teams
â—Ź Often different teams work on different layers
32
Layered Style - Liabilities
â—Ź It is hard to decompose the system into different-
levels of abstraction
â—Ź What to abstract and what-not-to abstract requires
experience and business knowledge
● Also, defining API’s for each layer is challenging
â—Ź Especially hiding implementation details at the interface
level
â—Ź (Some-cases) Performance problems due to
indirections
â—Ź Implementation might skip layers
â—Ź Duplicate or cloned code to escape layer-usage rules
â—Ź Exceptions from low-level layers must also be
abstracted
33
Pipe-and-Filter Style
â—Ź Famous in Unix environment
● find . –name “*.c” | xargs cat | wc –l
â—Ź The above instruction count the total number of
lines in all c files
â—Ź find command list the files with .c extension
â—Ź cat command concatenates all files (using xargs)
● wc –l counts the number of lines
â—Ź Pipes (|) facilitate the co-ordination of filters (i.e.,
commands)
â—Ź Topology: Upward filter writes to a pipe and
downward filter reads from the pipe
34
Pipe-and-Filter Style
35
Pipe-and-Filter Style - Benefits
â—Ź Filters are not directly coupled to each other
â—Ź Filters can be composed with different filters to
produce new configurations
â—Ź Helps in producing system variants
â—Ź Filters can be tested independently
â—Ź Filters can be executed concurrently
36
Pipe-and-Filter Style – Liabilities
â—Ź It is hard to share data between non-adjacent
filters
â—Ź Error handling is very difficult
â—Ź If one intermediate filter fails then other filters
might get wrong-data
â—Ź Not easy to propagate errors upwards
â—Ź System could be in trouble if filters disagree on the
interaction protocol
37
Publish-Subscribe Arch Style
● Components don’t interact directly
â—Ź Components publish messages to a connector
(e.g. a message bus)
â—Ź Components subscribe to messages of interest to
the connector
â—Ź The connector delivers corresponding messages
to components
â—Ź Components often run asynchronously
Publish-Subscribe
Inter-task Message Router (SW Bus)
Transponders
Commands
Real-time Telemetry
(UDP)
Comm Cards
File downlink
(CFDP)
Summit
Chip
Mass
Storage
System
CFDP File
Transfer
File
Manager
Local
Storage
Data
Storage
Event
Services
Executive
Services
Time
Services
1553 Bus
Support
Software
Bus
Command
Ingest
Telemetry
Output
Table
Services
EDA
CMemor
yScrubber
Self
Test
Memor
yDwel
l
Instrument
Manager
Checksum
Memor
yManager
GN&C
Applications
(4)
Mission Apps
cFE core App
CFS Applications
Stored
Commanding
Software
Scheduler
Health
&Safety
Manager
House-
keeping
Limit
Checker
39
Publish-Subscribe - Benefits
â—Ź Components are not coupled to each other
â—Ź New components can be added/removed at run-
time
â—Ź Components can also dynamically unsubscribe to
subscribed messages
â—Ź New variants of the system can be produced with
different configurations of components
â—Ź The connector takes care of delivering messages
to components
40
Publish-Subscribe - Liabilities
● There is overhead due to the connector’s routing
algorithm
â—Ź Actual topology is known only at run-time
â—Ź Hard to analyze the implemented system because
the control and data-flow information are not
easy to track
â—Ź The correctness of the connector is very crucial
â—Ź If the message bus is not reliable then messages
might be delivered to wrong subscribers
41
Implicit Invocation Style
â—Ź Components call other components implicitly
â—Ź Components register their interest to certain
events to other components
â—Ź When events happen all interested components
(i.e., event listeners) get invoked implicitly
â—Ź This style is commonly found in UI
● For example, please call me “if mouse click event
happens”
42
Implicit Invocation Style - Benefits
● Components don’t know the identify of
components they interact
â—Ź A component can be composed with a different
component
43
Implicit Invocation Style - Liabilities
â—Ź System structure is often not intuitive
â—Ź Static analysis of the source code to extract the
architecture is very hard due to indirections
â—Ź The model is event driven. One event is triggered
by the occurrence of another event
â—Ź Proving/testing correctness of the system can be
hard
44
Arch Styles for Net-Centric systems
â—Ź Components of a distributed system often run in
different computers
â—Ź Components communicate through connectors:
â—Ź Remote procedure calls (as in RMI)
â—Ź Brokers (as in CORBA)
â—Ź Sockets (TCP/UDP)
45
Client-Server Arch. Style
â—Ź Two types of components: Client, Server
â—Ź Client request the server for its service
â—Ź Server give response to the client
â—Ź Client and Server can run in different machines
asynchronously
â—Ź Connectors (e.g., Sockets) help connecting clients
to servers
46
Client-Server Arch Style …
SAM DsDm
SDIF
MOC Client
OAM c s
c
s
s
s
s
s
SVE
c
c
c
c
c c
s s
c
c
s
SNI
F
c
c
c
c
c
c
NCCD
S
s
s
s
s
s
s
DASs
c
s
s s s s s s
c
Client-side
Socket
s
Server-side Socket
47
Client-Server Arch. Style - Benefits
â—Ź Intuitive structure based on request/response
paradigm
â—Ź Clear separation of responsibilities among the
client and server
â—Ź Many clients can use a server
â—Ź Client and server can run concurrently
48
Client-Server Arch. Style - Liabilities
â—Ź Server must handle heavy traffic (if applicable)
â—Ź Also Load balancing is needed
â—Ź Additional complexity due to:
â—Ź Thread creation/termination per connection , or
â—Ź Thread pool management, or
â—Ź Managing queue of requests from clients
â—Ź Must be prepared to handle network failures
49
Composing Styles
â—Ź Often large systems are made of many different
styles
â—Ź For example:
â—Ź the high-level structure could be a layer, and
â—Ź components within a layer could follow
publish/subscribe architecture style
â—Ź two adjacent layers could interact through a pipe
â—Ź Styles can be safely composed as long as they
don’t violate style constraints
50
Composing Styles …
â—Ź In practice, often performance is the main criteria
for
â—Ź selecting the styles
â—Ź composing the styles
â—Ź Architects typically perform a trade-off analysis
or based on their experience select and compose
styles
â—Ź Select and compose styles based on quality
properties (e.g., Usability, Performance) for your
system
53
What’s On The Agenda
â—Ź Software Architecture
â—Ź Introduction and Motivation
â—Ź Architecture vs. Design
â—Ź Software Connectors
â—Ź Software Architectural Styles
â—Ź Introduction and Motivation
â—Ź Types of Styles
â—Ź Software Architecture Description
â—Ź Introduction and Motivation
â—Ź Viewpoints, Views,
â—Ź Consistency across Views
â—Ź Architectural Perspectives and Quality
â—Ź Software Architecture for Product Lines
â—Ź Introduction and Motivation
â—Ź Architecting for Variability and Commonality
54
Software Architecture Description
â—Ź There is no common consensus on what an architecture
description (AD) should contain
â—Ź Typically, AD contains system-level design decisions that
are of concern to the whole system and everyone should
be aware of
â—Ź AD should contain, for example:
â—Ź High-level components,
â—Ź Connectors that connect the components
â—Ź Protocol of interactions among components
● Error handling strategy – how exceptions are handled?
● Concurrency model – how multiple clients are handled by
a single server?
● Data or information flow – how data/information is
passed between components?
55
Describing Software Architecture
using Views
â—Ź How to best describe Software Architecture
is a topic of on-going R&D
â—Ź In literature, views are used to describe
Software Architecture
â—Ź Each view address one concern, for example:
â—Ź Structural view shows the decomposition of
system
â—Ź Behavioral view shows how components
interact at run-time
â—Ź Deployment view shows how components
are assigned to hardware elements
56
Viewpoints and Views (IEEE 1471
Standard Defn)
â—Ź A view is a representation of all or part of
an architecture, from the perspective of
one or more concerns which are held by
one or more of its stakeholders.
â—Ź A viewpoint is a collection of patterns,
templates and conventions for constructing
one type of view.
Viewpoints, Views, and Architectural
Description
Viewpoint View
Architectural
Description
defines 0..n
1 .. n
•An architectural description is a collection of one or more views.
•A viewpoint is used to define (the structure and content of) zero
or more views.
•The structure and content of a particular view is defined by
exactly one viewpoint.
58
Some Approaches for Describing
Software Architecture
●Kruchten “4 + 1” View
â—ŹSiemens View
â—ŹSEI View
â—ŹPhilips View
â—ŹRozanski and Woods View
59
Kruchten 4 + 1 View
Viewpoint Definition
Logical The logical representation of the system’s functional
structure.
Process The concurrency and synchronization aspects of the
architecture.
Development The design-time software structure, identifying modules,
and subsystems.
Physical The identification of the nodes that the system’s software
will be executed on and the mapping of other architectural
elements to these nodes.
Scenarios
(+1)
A set of functional usage scenarios to illustrate how the
views work together.
As a driver to discover architectural elements during the
architectural design.
60
Siemens View
Viewpoint Definition
Conceptual The conceptual functional structure of the system that
defines a set of conceptual components linked by a set of
connectors.
Module The concrete structure of the subsystems and modules that
will be realized in the system, the interfaces exposed by the
modules, the intermodule dependencies, and any layering
constraints in the structure.
Execution The runtime structure of the system in terms of processes,
threads, interprocess communication elements, and so on
along with a mapping of modules to runtime elements.
Code The design-time layout of the system as source code and the
intermediate and delivered binary elements created from it.
61
SEI View
Viewtype Definition
Component
and Connector
It is concerned with the sytem’s runtime functional
elements, their behaviors, and their interactions.
The following styles defined for this viewtype all relate
to commonly occurring runtime system organizations:
• Pipe-and-Filter
• Shared-Data
• Publish-Subscribe
• Client-Server
• Peer-to-Peer
• Communicating-Processes
62
SEI View…
Viewtype Definition
Module The module viewtype is concerned with the how the software
comprising the system is structured as a set of
implementation (code) units.
The following styles are defined for the Module viewtype:
• Uses: for capturing inter-module usage dependencies
• Generalization: for capturing commonality and variation
(inheritance) relationships between modules
• Decomposition: for specifying how modules are composed
from simpler elements
• Layered: for specifying how modules are arranged in layers
according to their level of abstraction
63
SEI View …
Viewtype Definition
Allocation It is concerned with how relationships between the different
parts of the system and different aspects of their
environment are captured.
The following styles are defined for this viewtype:
• Deployment: for specifying how software elements are
mapped to elements of the deployment environment
• Implementation: for specifying how software modules are
mapped to the development environment (such as their
location in a codebase)
• Work assignment: for mapping software modules to those
responsible for creating, testing, and deploying them.
64
Philips View (BAPO)
Viewpoint Primary Focus
Business Goals of the business
Architecture Decisions based on Business Goals
Process Policies and Planning. E.g., change management, Version
Control, Project plans
Organization Structure of development teams, and reporting hierarchy.
Philips BAPO
Rozanksi and Woods View
Functional Viewpoint
Information Viewpoint
Concurrency Viewpoint
Development Viewpoint
Deployment Viewpoint
Operational Viewpoint
The Functional, Information, and Concurrency
viewpoints characterize the fundamental
organization of the system.
The Development viewpoint exists to support
the system’s construction.
The Deployment and Operational viewpoints
characterize the system once in its
live environment.
67
Rozanksi and Woods View …
Viewpoint Definition
Information Describes the way that the architecture
stores, manipulates, manages, and
distributes information.
The aim of this viewpoint is to identify
structure, ownership, latency, references,
and data migration.
Operational Describes how the system will be operated,
administered, and supported when it is
running in its production environment.
Installing, managing, and operating the
system are the concerns of interest to this
viewpoint.
View Relationships
Deployment
View
Operational
View
Software
Structure
Development
View
Functional
View
Information
View
Concurrency
View
defines operation of
defines
deployment of
defines implementation
constraints for
69
Functional View (some examples)
â—Ź Cranefoot is a tool for visualizing Pedigrees
(family history tree) used in genetic studies
70
Dependency Structure of Cranefoot
71
Mapping Structural Elements to Files
72
Execution View of Cranefoot
Cranefoot runs on a single thread in a single machine
– thus no separate process view was documented
73
Consistency across Views
â—Ź Views helped us with the partitioning the
representation of our architecture
â—Ź But, the challenge is how to ensure consistency
between them
â—Ź How to ensure that the structures, features, and
elements that appear in one view are compatible
and in alignment with the content of other views?
74
Consistency across Views …
â—Ź Consistency is a vital characteristics of our Architecture
Description
â—Ź Without consistency, the system:
â—Ź will not work properly
â—Ź will not achieve its design goals
â—Ź may even be impossible to build
â—Ź Arguably, no tools automate consistency between views
â—Ź Ensuring consistency comes down to the skill,
thoroughness, and diligence of the architect
â—Ź Checklists could help during reviews (coming next)
75
Functional and Concurrency View
Consistency – Sample Checklist
â—Ź Goal: To ensure that the functional elements are
all mapped to a task that will allow them to
execute and the inter-element interactions are
supported by the IPC mechanisms if required
➢Is every functional element in the Functional
view mapped to a concurrent element (a process
or thread) responsible for its execution in the
Concurrency view?
76
Functional and Deployment View
Consistency – Sample Checklist
â—Ź Goal: To ensure that each of the functional
elements is correctly mapped to its deployment
environment.
➢Has each functional element been mapped to a
processing node to allow it to be executed?
➢Where functional elements are hosted on
different nodes, do the network models allow the
required element interactions to occur?
77
Functional and Deployment View
Consistency – Sample Checklist …
➢Are functional elements that need to interact
extensively hosted as close together as possible?
➢Are the specified network connections sufficient
for the needs of the interelement interactions that
will be carried over them (in terms of capacity,
reliability, security, and so on)?
➢Is the hardware specified in the Deployment view
the most efficient solution for hosting the
specified functional elements?
78
Functional and Operational View
Consistency – Sample Checklist
â—Ź Goal: To ensure that each of the specified
functional elements can be installed, used,
operated, and supported.
➢Does the Operational view make it clear how
every functional element will be installed?
➢Does the Operational view explain how each
functional element will be monitored and
controlled in the production environment?
79
Information and Concurrency view
Consistency
â—Ź Goal: To ensure that the concurrency structure of the
system does not cause data access problems and that
the proposed information structure is compatible
with the concurrency structure.
➢Does the concurrency design imply concurrent access
to any of the system’s data elements?
â—Ź If so, have the data elements been protected from
concurrent access problems?
➢If functional elements that share data elements are
packaged into different OS processes, has a suitable
inter-process data-sharing mechanism been defined?
80
Information and Deployment View
Consistency
â—Ź Goal: To ensure that the proposed deployment
environment provides the resources required to support
the defined information structure.
➢ Does the Deployment view include enough storage to
support the information specified by the Information
view?
➢ If large volumes of information need to be moved, is
sufficient bandwidth available so that this can be achieved
without performance issues?
➢ Does the Deployment view reflect the requirements for
backup and recovery as addressed by the Info. View?
81
Concurrency and Development view
Consistency
â—Ź Goal: To ensure that the concurrency structure specified in the
concurrency view can be built and tested in the development
environment specified by the Development view.
➢ If the concurrency structure is complex, are sufficient design
patterns specified in the Development view to guide its
implementation?
➢ Does the code structure defined in the Development view
support the packaging of the system’s functional elements into
the operating system processes specified by the Concurrency
view?
➢ Does the test approach defined in the Development view
support the concurrency structure specified in the Concurrency
view?
82
Architectural Perspectives
â—Ź A viewpoint advises on how to create and
describe a particular type of architectural
structure (e.g., Concurrency, Information)
â—Ź A perspective provides advice relating to the
cross view concerns of a particular quality
property (e.g., Security, Performance)
â—Ź Architectural perspectives provide a framework
for structuring knowledge about how to design
systems to achieve quality
83
Examples of Applying Perspectives
to Views
Security Performance Availability Evolution
OperationalConcurrencyInformationFunctional
PERSPECTIVES
VIEWS
Information
Security
(Access control)
Functional
Evolution
(extension points,
flexible interfaces)
Concurrency
Performance
(shared resources,
blocking, queuing)
84
Structure of a Perspective
â—Ź the Concerns that the perspective is addressing
â—Ź the Applicability of the perspective to the different
possible architectural views
â—Ź a set of possible Activities for achieving the
quality property
â—Ź a set of proven Architectural Tactics or strategies
â—Ź a list of common Problems and Pitfalls
â—Ź a Checklist to ensure nothing has been forgotten
➢Let us see an example of Security perspective
85
Concerns of Security Persp.
â—Ź Policy (the actions that difference principals can
perform on sensitive resources)
â—Ź Threats (the security threats that the system faces)
â—Ź Governance (the mechanisms for implementing
the policy securely, including authentication,
authorization, confidentiality, integrity and
accountability)
â—Ź Availability (ensuring that attackers cannot
prevent access to a system)
â—Ź Detection and Recovery from Breach (allowing
recovery when security fails)
86
Views applicable to Security
â—Ź Deployment view
â—Ź Adding security related hardware and software
â—Ź Development view
â—Ź Setting system wide security related standards
â—Ź Functional view
â—Ź Partitioning the system differently to allow
controlled access to sensitive parts
87
Activities for Security
â—Ź Identification of sensitive resources
â—Ź Definition of a security policy
â—Ź Creation of a threat model
â—Ź Design of a security implementation
â—Ź Assessment of security risk
88
Architectural tactics for Security
â—Ź Application of recognized security principles:
â—Ź Example: least privilege, auditing
â—Ź Principal identification mechanisms
â—Ź Access control mechanisms
â—Ź Information protection mechanisms
â—Ź Provision of security administration
â—Ź Use of 3rd party security technology
89
Problems and Pitfalls of Security
â—Ź Complex security policies
â—Ź Use of unproven security technology
â—Ź Not designing for secure failure conditions
â—Ź Not providing effective admin facilities
â—Ź Leaving security as an afterthought
â—Ź Use of ad-hoc technology to enforce security
â—Ź Driving the process by technology choice rather
than security threats
90
Checklist for Security
â—Ź Is there a clear policy that defines which
principals are allowed to perform which
operations on which resources?
â—Ź Is the security policy as simple as possible?
â—Ź Have security requirements been reviewed with
external experts?
â—Ź Has each threat identified in the threat model
been addressed to the extent necessary?
● …
91
Core set of Perspectives
Perspective Purpose
Security Ensure who can perform what actions on resources
Performance
and Scalability
Ensure the system’s ability to predictably execute within
its mandated performance req. and to handle increasing
processing volumes
Availability
and Resilience
Ensure the system’s ability to be fully or partly
operational. Effectively handle failures.
Evolution Ensure the system’s flexibility to change
92
Other Perspectives
Perspective Purpose
Internationalization Ensure the system’s independence from any
particular language, country or cultural group.
Accessibility Ensure the ability of the system to be used by people
with disabilities.
Usability Ensure that people who interact with the system can
easily work effectively.
Regulation Ensure the ability of the system to comply with local
and international laws, regulations, policies, etc.,
Development
Resource
Ensure that the system can be designed, built, and
operated within constraints around people, budget.
Licensing Ensure that the system has appropriate licensing
mechanism in place according to marketing plans.
Using Perspectives
Analyse and
Understand Key
requirements
Create a Candidate
Architecture
Apply Perspectives Modify Architecture
Perform “Formal”
Architectural
Evaluation
(e.g., Scenario-based
methods ATAM,
SAAM)
[Unacceptable
properties]
[acceptable properties]
94
What’s On The Agenda
â—Ź Software Architecture
â—Ź Introduction and Motivation
â—Ź Architecture vs. Design
â—Ź Software Connectors
â—Ź Software Architectural Styles
â—Ź Introduction and Motivation
â—Ź Types of Styles
â—Ź Software Architecture Description
â—Ź Introduction and Motivation
â—Ź Viewpoints, Views,
â—Ź Consistency across Views
â—Ź Architectural Perspectives and Quality
â—Ź Software Architecture for Product Lines
â—Ź Introduction and Motivation
â—Ź Architecting for Variability and Commonality
95
Product Line
96
Software Product Line - Examples
97
SPL – Examples …
98
SPL Definition
â—Ź A software product line is a set of software-intensive
systems sharing a common, managed set of features
that satisfy the specific needs of a particular market
segment or mission and that are developed from a
common set of core assets in a prescribed way.
â—Ź SPL
â—Ź take economic advantage of commonality
â—Ź bound variation
â—Ź PRODUCT LINES = STRATEGIC REUSE
99
Economics of SPL
100
Motivation for SPL
â—Ź Achieve large scale productivity gains
â—Ź Improve time to market
â—Ź Enable mass customization
â—Ź Get control of diverse product configurations
â—Ź Improve product quality
â—Ź Increase predictability of cost, schedule, and
quality
➢The product line architecture is central to success
101
Architecting for SPL
â—Ź Two of the fundamental needs in defining an
architecture for a product line are
â—Ź to be able to generalize or abstract from the
individual products to capture the important
aspects of the product line
â—Ź to be able to instantiate an individual product
architecture from the product line architecture
â—Ź Having a product line implies having a generic
architecture from which the individual product
architectures can be derived in some manner
102
Architecting for SPL …
â—Ź Use Architectural styles to handle variation
â—Ź For example, a Pipe-and-Filter style can be used to
produce different product instances
â—Ź Select Filters of interest and produce new config.
● Use a Layered architectural style to “hide” variations
in OS and Hardware
â—Ź Important to define Abstract APIs with alternative
implementations
â—Ź Use a Publish-Subscribe style for:
â—Ź Substituting various publishers and subscribers
â—Ź Plug-in new publishers and subscribers
â—Ź Run-time adaptation
Architecture-level Variability
Inter-task Message Router (SW Bus)
Transponders
Commands
Real-time Telemetry
(UDP)
Comm Cards
File downlink
(CFDP)
Summit
Chip
Mass
Storage
System
CFDP File
Transfer
File
Manager
Local
Storage
Data
Storage
Event
Services
Executive
Services
Time
Services
1553 Bus
Support
Software
Bus
Command
Ingest
Telemetry
Output
Table
Services
EDA
CMemor
yScrubber
Self
Test
Memor
yDwel
l
Instrument
Manager
Checksum
Memor
yManager
GN&C
Applications
(4)
Mission Apps
cFE core App
CFS Applications
Stored
Commanding
Software
Scheduler
Health
&Safety
Manager
House-
keeping
Limit
Checker
104
Variation within Components
â—Ź Configurable component (e.g., Properties, #ifdef)
â—Ź Variation is supported within the component
â—Ź Select appropriate values for config. parameters
â—Ź Enable/disable parts of code using config. param.
â—Ź Extensible component (e.g., Inheritance)
â—Ź Consists of an extensible base
â—Ź Variable parts are separate sub-components
â—Ź Generic and specific functionality are separated
â—Ź Abstract component (e.g., Java Interface)
â—Ź Only the interface is provided
â—Ź Different products must provide own implementation
â—Ź Suitable when implementation differs a lot
105
Example: Variation within OS
Abstraction Layer
â—Ź Software Bus requires a communication mechanism
internally
â—Ź The OS abstraction layer offers two implementations:
â—Ź Socket, or
â—Ź Queue
â—Ź At preprocessing time this variation point must be
resolved
â—Ź Software Bus uses the same API for both
communication mechanisms
Variation within OS Abstraction
Layer…
/****************************************************************************************
MESSAGE QUEUE API
****************************************************************************************/
#ifdef OSAL_SOCKET_QUEUE
int32 OS_QueueCreate (uint32 *queue_id, const char *queue_name, uint32 queue_depth
uint32 data_size, uint32 flags) {
…
socket(AF_INET, SOCK_DGRAM, 0); …
}
#else
/* ---------------------- POSIX MESSAGE QUEUE IMPLEMENTATION -------------------- */
int32 OS_QueueCreate (uint32 *queue_id, const char *queue_name, uint32 queue_depth
uint32 data_size, uint32 flags) {
….
mq_open(name, O_CREAT | O_RDWR, …);
}
107
References/Further reading
1. P. Kruchten. Architectural Blueprints – The “4+1” View Model of the Software Architecture. IEEE Software
12(6), Nov 1995, pp. 42-50.
1. D. Ganesan. The Software Architecture of Cranefoot. - An independent analysis by Fraunhofer,
Maryland, USA, 2009.
1. D. Ganesan, M. Lindvall, C. Ackermann, D. McComas, and M. Bartholomew. Verifying Architectural
Design Rules of the Flight Software Product Line. IEEE Proceedings of Software Product Line Conference,
2009.
1. N. Rozanski, E. Woods. Software Systems Architecture. Addison-Wesley.
1. R. N. Taylor, N. Medvidovic, E. M. Dashofy. Software Architecture. Foundations, Theory, and Practice.
Addison-Wesley.
1. M. Shaw, D. Garlan. Software Architecture – Perspectives on an Emerging Discipline. Prentice Hall, 1996.
1. F. Buschmann et al. Pattern-Oriented Software Architecture. Addison-Wesley, 2001.
1. J. Mehdi, A. Ran, and F. van der Linden. Software Architecture for Product Families: Principles and
Practice. Addison-Wesley, 2000.
108
References/ Further Reading
9. C. Hofmeister et al. Generalizing a Model of
Software Architecture Design from Five Industrial
Approaches. IEEE Proceedings of Working
Conference on Software Architecture, 2005.

More Related Content

What's hot

Data Designs (Software Engg.)
Data Designs (Software Engg.)Data Designs (Software Engg.)
Data Designs (Software Engg.)Arun Shukla
 
Software Process Models
Software Process ModelsSoftware Process Models
Software Process ModelsAtul Karmyal
 
Architecture design in software engineering
Architecture design in software engineeringArchitecture design in software engineering
Architecture design in software engineeringPreeti Mishra
 
Software Engineering : Requirement Analysis & Specification
Software Engineering : Requirement Analysis & SpecificationSoftware Engineering : Requirement Analysis & Specification
Software Engineering : Requirement Analysis & SpecificationAjit Nayak
 
REQUIREMENT ENGINEERING
REQUIREMENT ENGINEERINGREQUIREMENT ENGINEERING
REQUIREMENT ENGINEERINGSaqib Raza
 
Introduction to Software Project Management
Introduction to Software Project ManagementIntroduction to Software Project Management
Introduction to Software Project ManagementReetesh Gupta
 
SRS(software requirement specification)
SRS(software requirement specification)SRS(software requirement specification)
SRS(software requirement specification)Akash Kumar Dhameja
 
Design concept -Software Engineering
Design concept -Software EngineeringDesign concept -Software Engineering
Design concept -Software EngineeringVarsha Ajith
 
An Introduction to Software Architecture
An Introduction to Software ArchitectureAn Introduction to Software Architecture
An Introduction to Software ArchitectureRahimLotfi
 
Software Engineering (Project Scheduling)
Software Engineering (Project Scheduling)Software Engineering (Project Scheduling)
Software Engineering (Project Scheduling)ShudipPal
 
Design Pattern in Software Engineering
Design Pattern in Software EngineeringDesign Pattern in Software Engineering
Design Pattern in Software EngineeringManish Kumar
 
Software requirements
Software requirementsSoftware requirements
Software requirementsDr. Loganathan R
 
Software quality assurance
Software quality assuranceSoftware quality assurance
Software quality assuranceAman Adhikari
 
Introduction to Design Pattern
Introduction to Design  PatternIntroduction to Design  Pattern
Introduction to Design PatternSanae BEKKAR
 
Design Patterns
Design PatternsDesign Patterns
Design PatternsAnuja Arosha
 
Overview of UML Diagrams
Overview of UML DiagramsOverview of UML Diagrams
Overview of UML DiagramsManish Kumar
 
Software engineering : Layered Architecture
Software engineering : Layered ArchitectureSoftware engineering : Layered Architecture
Software engineering : Layered ArchitectureMuhammed Afsal Villan
 

What's hot (20)

Data Designs (Software Engg.)
Data Designs (Software Engg.)Data Designs (Software Engg.)
Data Designs (Software Engg.)
 
Software Process Models
Software Process ModelsSoftware Process Models
Software Process Models
 
Architecture design in software engineering
Architecture design in software engineeringArchitecture design in software engineering
Architecture design in software engineering
 
Software Engineering : Requirement Analysis & Specification
Software Engineering : Requirement Analysis & SpecificationSoftware Engineering : Requirement Analysis & Specification
Software Engineering : Requirement Analysis & Specification
 
REQUIREMENT ENGINEERING
REQUIREMENT ENGINEERINGREQUIREMENT ENGINEERING
REQUIREMENT ENGINEERING
 
Introduction to Software Project Management
Introduction to Software Project ManagementIntroduction to Software Project Management
Introduction to Software Project Management
 
SRS(software requirement specification)
SRS(software requirement specification)SRS(software requirement specification)
SRS(software requirement specification)
 
Design concept -Software Engineering
Design concept -Software EngineeringDesign concept -Software Engineering
Design concept -Software Engineering
 
An Introduction to Software Architecture
An Introduction to Software ArchitectureAn Introduction to Software Architecture
An Introduction to Software Architecture
 
Software Engineering (Project Scheduling)
Software Engineering (Project Scheduling)Software Engineering (Project Scheduling)
Software Engineering (Project Scheduling)
 
Design Pattern in Software Engineering
Design Pattern in Software EngineeringDesign Pattern in Software Engineering
Design Pattern in Software Engineering
 
UML Diagrams
UML DiagramsUML Diagrams
UML Diagrams
 
Software requirements
Software requirementsSoftware requirements
Software requirements
 
Software quality assurance
Software quality assuranceSoftware quality assurance
Software quality assurance
 
Introduction to Design Pattern
Introduction to Design  PatternIntroduction to Design  Pattern
Introduction to Design Pattern
 
Design Patterns
Design PatternsDesign Patterns
Design Patterns
 
Software design
Software designSoftware design
Software design
 
Unified process Model
Unified process ModelUnified process Model
Unified process Model
 
Overview of UML Diagrams
Overview of UML DiagramsOverview of UML Diagrams
Overview of UML Diagrams
 
Software engineering : Layered Architecture
Software engineering : Layered ArchitectureSoftware engineering : Layered Architecture
Software engineering : Layered Architecture
 

Similar to Software Architecture

Unit v -Construction and Evaluation
Unit v -Construction and EvaluationUnit v -Construction and Evaluation
Unit v -Construction and EvaluationDhivyaa C.R
 
Reverse Architecting using Relation Algebra.pdf
Reverse Architecting using Relation Algebra.pdfReverse Architecting using Relation Algebra.pdf
Reverse Architecting using Relation Algebra.pdfDharmalingam Ganesan
 
Web and Android App Development
Web and Android App DevelopmentWeb and Android App Development
Web and Android App DevelopmentGaurav Gopal Gupta
 
object oriented programming part inheritance.pptx
object oriented programming part inheritance.pptxobject oriented programming part inheritance.pptx
object oriented programming part inheritance.pptxurvashipundir04
 
25896027-1-ODI-Architecture.ppt
25896027-1-ODI-Architecture.ppt25896027-1-ODI-Architecture.ppt
25896027-1-ODI-Architecture.pptAnamariaFuia
 
02 - Angular Structural Elements - 1.pdf
02 - Angular Structural Elements - 1.pdf02 - Angular Structural Elements - 1.pdf
02 - Angular Structural Elements - 1.pdfBrunoOliveira631137
 
Object oriented sad-5 part i
Object oriented sad-5 part iObject oriented sad-5 part i
Object oriented sad-5 part iBisrat Girma
 
Pullareddy_tavva_resume.doc
Pullareddy_tavva_resume.docPullareddy_tavva_resume.doc
Pullareddy_tavva_resume.docT Pulla Reddy
 
Unit 4 final
Unit 4 finalUnit 4 final
Unit 4 finalsietkcse
 
Arch06 1
Arch06 1Arch06 1
Arch06 1nazn
 
Software design of library circulation system
Software design of  library circulation systemSoftware design of  library circulation system
Software design of library circulation systemMd. Shafiuzzaman Hira
 
Fast federated SQL with Apache Calcite
Fast federated SQL with Apache CalciteFast federated SQL with Apache Calcite
Fast federated SQL with Apache CalciteChris Baynes
 
Best Practices with Sitecore
Best Practices with SitecoreBest Practices with Sitecore
Best Practices with SitecoreAnant Corporation
 
fy21-bim-interoperability-guide-en.pdf
fy21-bim-interoperability-guide-en.pdffy21-bim-interoperability-guide-en.pdf
fy21-bim-interoperability-guide-en.pdfFabioAmaya5
 
Carlo Bonamico, Sonia Pini - So you want to build your (Angular) Component Li...
Carlo Bonamico, Sonia Pini - So you want to build your (Angular) Component Li...Carlo Bonamico, Sonia Pini - So you want to build your (Angular) Component Li...
Carlo Bonamico, Sonia Pini - So you want to build your (Angular) Component Li...Codemotion
 

Similar to Software Architecture (20)

Unit v -Construction and Evaluation
Unit v -Construction and EvaluationUnit v -Construction and Evaluation
Unit v -Construction and Evaluation
 
Reverse Architecting using Relation Algebra.pdf
Reverse Architecting using Relation Algebra.pdfReverse Architecting using Relation Algebra.pdf
Reverse Architecting using Relation Algebra.pdf
 
Web and Android App Development
Web and Android App DevelopmentWeb and Android App Development
Web and Android App Development
 
object oriented programming part inheritance.pptx
object oriented programming part inheritance.pptxobject oriented programming part inheritance.pptx
object oriented programming part inheritance.pptx
 
Embedded Linux - Building toolchain
Embedded Linux - Building toolchainEmbedded Linux - Building toolchain
Embedded Linux - Building toolchain
 
FIFODC
FIFODCFIFODC
FIFODC
 
25896027-1-ODI-Architecture.ppt
25896027-1-ODI-Architecture.ppt25896027-1-ODI-Architecture.ppt
25896027-1-ODI-Architecture.ppt
 
02 - Angular Structural Elements - 1.pdf
02 - Angular Structural Elements - 1.pdf02 - Angular Structural Elements - 1.pdf
02 - Angular Structural Elements - 1.pdf
 
SMD.pptx
SMD.pptxSMD.pptx
SMD.pptx
 
Object oriented sad-5 part i
Object oriented sad-5 part iObject oriented sad-5 part i
Object oriented sad-5 part i
 
Pullareddy_tavva_resume.doc
Pullareddy_tavva_resume.docPullareddy_tavva_resume.doc
Pullareddy_tavva_resume.doc
 
software Design.ppt
software Design.pptsoftware Design.ppt
software Design.ppt
 
Unit 4 final
Unit 4 finalUnit 4 final
Unit 4 final
 
Arch06 1
Arch06 1Arch06 1
Arch06 1
 
Software design of library circulation system
Software design of  library circulation systemSoftware design of  library circulation system
Software design of library circulation system
 
Fast federated SQL with Apache Calcite
Fast federated SQL with Apache CalciteFast federated SQL with Apache Calcite
Fast federated SQL with Apache Calcite
 
Best Practices with Sitecore
Best Practices with SitecoreBest Practices with Sitecore
Best Practices with Sitecore
 
Web dynpro
Web dynproWeb dynpro
Web dynpro
 
fy21-bim-interoperability-guide-en.pdf
fy21-bim-interoperability-guide-en.pdffy21-bim-interoperability-guide-en.pdf
fy21-bim-interoperability-guide-en.pdf
 
Carlo Bonamico, Sonia Pini - So you want to build your (Angular) Component Li...
Carlo Bonamico, Sonia Pini - So you want to build your (Angular) Component Li...Carlo Bonamico, Sonia Pini - So you want to build your (Angular) Component Li...
Carlo Bonamico, Sonia Pini - So you want to build your (Angular) Component Li...
 

More from Dharmalingam Ganesan

.NET Deserialization Attacks
.NET Deserialization Attacks.NET Deserialization Attacks
.NET Deserialization AttacksDharmalingam Ganesan
 
Cyclic Attacks on the RSA Trapdoor Function
Cyclic Attacks on the RSA Trapdoor FunctionCyclic Attacks on the RSA Trapdoor Function
Cyclic Attacks on the RSA Trapdoor FunctionDharmalingam Ganesan
 
An Analysis of RSA Public Exponent e
An Analysis of RSA Public Exponent eAn Analysis of RSA Public Exponent e
An Analysis of RSA Public Exponent eDharmalingam Ganesan
 
An Analysis of Secure Remote Password (SRP)
An Analysis of Secure Remote Password (SRP)An Analysis of Secure Remote Password (SRP)
An Analysis of Secure Remote Password (SRP)Dharmalingam Ganesan
 
Active Attacks on DH Key Exchange
Active Attacks on DH Key ExchangeActive Attacks on DH Key Exchange
Active Attacks on DH Key ExchangeDharmalingam Ganesan
 
Can I write to a read only file ?
Can I write to a read only file ?Can I write to a read only file ?
Can I write to a read only file ?Dharmalingam Ganesan
 
How do computers exchange secrets using Math?
How do computers exchange secrets using Math?How do computers exchange secrets using Math?
How do computers exchange secrets using Math?Dharmalingam Ganesan
 
On the Secrecy of RSA Private Keys
On the Secrecy of RSA Private KeysOn the Secrecy of RSA Private Keys
On the Secrecy of RSA Private KeysDharmalingam Ganesan
 
Computing the Square Roots of Unity to break RSA using Quantum Algorithms
Computing the Square Roots of Unity to break RSA using Quantum AlgorithmsComputing the Square Roots of Unity to break RSA using Quantum Algorithms
Computing the Square Roots of Unity to break RSA using Quantum AlgorithmsDharmalingam Ganesan
 
Analysis of Short RSA Secret Exponent d
Analysis of Short RSA Secret Exponent dAnalysis of Short RSA Secret Exponent d
Analysis of Short RSA Secret Exponent dDharmalingam Ganesan
 
Dependency Analysis of RSA Private Variables
Dependency Analysis of RSA Private VariablesDependency Analysis of RSA Private Variables
Dependency Analysis of RSA Private VariablesDharmalingam Ganesan
 
Analysis of Shared RSA Modulus
Analysis of Shared RSA ModulusAnalysis of Shared RSA Modulus
Analysis of Shared RSA ModulusDharmalingam Ganesan
 
RSA without Integrity Checks
RSA without Integrity ChecksRSA without Integrity Checks
RSA without Integrity ChecksDharmalingam Ganesan
 
Solutions to online rsa factoring challenges
Solutions to online rsa factoring challengesSolutions to online rsa factoring challenges
Solutions to online rsa factoring challengesDharmalingam Ganesan
 
Security of RSA and Integer Factorization
Security of RSA and Integer FactorizationSecurity of RSA and Integer Factorization
Security of RSA and Integer FactorizationDharmalingam Ganesan
 

More from Dharmalingam Ganesan (20)

.NET Deserialization Attacks
.NET Deserialization Attacks.NET Deserialization Attacks
.NET Deserialization Attacks
 
How to exploit rand()?
How to exploit rand()?How to exploit rand()?
How to exploit rand()?
 
Cyclic Attacks on the RSA Trapdoor Function
Cyclic Attacks on the RSA Trapdoor FunctionCyclic Attacks on the RSA Trapdoor Function
Cyclic Attacks on the RSA Trapdoor Function
 
An Analysis of RSA Public Exponent e
An Analysis of RSA Public Exponent eAn Analysis of RSA Public Exponent e
An Analysis of RSA Public Exponent e
 
An Analysis of Secure Remote Password (SRP)
An Analysis of Secure Remote Password (SRP)An Analysis of Secure Remote Password (SRP)
An Analysis of Secure Remote Password (SRP)
 
Thank-a-Gram
Thank-a-GramThank-a-Gram
Thank-a-Gram
 
Active Attacks on DH Key Exchange
Active Attacks on DH Key ExchangeActive Attacks on DH Key Exchange
Active Attacks on DH Key Exchange
 
Can I write to a read only file ?
Can I write to a read only file ?Can I write to a read only file ?
Can I write to a read only file ?
 
How do computers exchange secrets using Math?
How do computers exchange secrets using Math?How do computers exchange secrets using Math?
How do computers exchange secrets using Math?
 
On the Secrecy of RSA Private Keys
On the Secrecy of RSA Private KeysOn the Secrecy of RSA Private Keys
On the Secrecy of RSA Private Keys
 
Computing the Square Roots of Unity to break RSA using Quantum Algorithms
Computing the Square Roots of Unity to break RSA using Quantum AlgorithmsComputing the Square Roots of Unity to break RSA using Quantum Algorithms
Computing the Square Roots of Unity to break RSA using Quantum Algorithms
 
Analysis of Short RSA Secret Exponent d
Analysis of Short RSA Secret Exponent dAnalysis of Short RSA Secret Exponent d
Analysis of Short RSA Secret Exponent d
 
Dependency Analysis of RSA Private Variables
Dependency Analysis of RSA Private VariablesDependency Analysis of RSA Private Variables
Dependency Analysis of RSA Private Variables
 
Analysis of Shared RSA Modulus
Analysis of Shared RSA ModulusAnalysis of Shared RSA Modulus
Analysis of Shared RSA Modulus
 
RSA Game using an Oracle
RSA Game using an OracleRSA Game using an Oracle
RSA Game using an Oracle
 
RSA Two Person Game
RSA Two Person GameRSA Two Person Game
RSA Two Person Game
 
RSA without Integrity Checks
RSA without Integrity ChecksRSA without Integrity Checks
RSA without Integrity Checks
 
RSA without Padding
RSA without PaddingRSA without Padding
RSA without Padding
 
Solutions to online rsa factoring challenges
Solutions to online rsa factoring challengesSolutions to online rsa factoring challenges
Solutions to online rsa factoring challenges
 
Security of RSA and Integer Factorization
Security of RSA and Integer FactorizationSecurity of RSA and Integer Factorization
Security of RSA and Integer Factorization
 

Recently uploaded

Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...kellynguyen01
 
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio, Inc.
 
cybersecurity notes for mca students for learning
cybersecurity notes for mca students for learningcybersecurity notes for mca students for learning
cybersecurity notes for mca students for learningVitsRangannavar
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...MyIntelliSource, Inc.
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfkalichargn70th171
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...ICS
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...stazi3110
 
DNT_Corporate presentation know about us
DNT_Corporate presentation know about usDNT_Corporate presentation know about us
DNT_Corporate presentation know about usDynamic Netsoft
 
Asset Management Software - Infographic
Asset Management Software - InfographicAsset Management Software - Infographic
Asset Management Software - InfographicHr365.us smith
 
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...gurkirankumar98700
 
Project Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationProject Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationkaushalgiri8080
 
The Evolution of Karaoke From Analog to App.pdf
The Evolution of Karaoke From Analog to App.pdfThe Evolution of Karaoke From Analog to App.pdf
The Evolution of Karaoke From Analog to App.pdfPower Karaoke
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVshikhaohhpro
 
Cloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackCloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackVICTOR MAESTRE RAMIREZ
 
EY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityEY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityNeo4j
 
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASEBATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASEOrtus Solutions, Corp
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsAlberto González Trastoy
 
Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)OPEN KNOWLEDGE GmbH
 
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfThe Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfkalichargn70th171
 

Recently uploaded (20)

Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
 
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
 
cybersecurity notes for mca students for learning
cybersecurity notes for mca students for learningcybersecurity notes for mca students for learning
cybersecurity notes for mca students for learning
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
 
DNT_Corporate presentation know about us
DNT_Corporate presentation know about usDNT_Corporate presentation know about us
DNT_Corporate presentation know about us
 
Call Girls In Mukherjee Nagar 📱 9999965857 🤩 Delhi 🫦 HOT AND SEXY VVIP 🍎 SE...
Call Girls In Mukherjee Nagar 📱  9999965857  🤩 Delhi 🫦 HOT AND SEXY VVIP 🍎 SE...Call Girls In Mukherjee Nagar 📱  9999965857  🤩 Delhi 🫦 HOT AND SEXY VVIP 🍎 SE...
Call Girls In Mukherjee Nagar 📱 9999965857 🤩 Delhi 🫦 HOT AND SEXY VVIP 🍎 SE...
 
Asset Management Software - Infographic
Asset Management Software - InfographicAsset Management Software - Infographic
Asset Management Software - Infographic
 
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
 
Project Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationProject Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanation
 
The Evolution of Karaoke From Analog to App.pdf
The Evolution of Karaoke From Analog to App.pdfThe Evolution of Karaoke From Analog to App.pdf
The Evolution of Karaoke From Analog to App.pdf
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTV
 
Cloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackCloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStack
 
EY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityEY_Graph Database Powered Sustainability
EY_Graph Database Powered Sustainability
 
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASEBATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
 
Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)
 
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfThe Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
 

Software Architecture

  • 1. Dharmalingam Ganesan Software Architecture – Insights from Practice
  • 2. 2 What’s On The Agenda â—Ź Software Architecture â—Ź Introduction and Motivation â—Ź Architecture vs. Design â—Ź Software Connectors â—Ź Software Architectural Styles â—Ź Introduction and Motivation â—Ź Types of Styles â—Ź Software Architecture Description â—Ź Introduction and Motivation â—Ź Viewpoints, Views, â—Ź Consistency across Views â—Ź Architectural Perspectives and Quality â—Ź Software Architecture for Product Lines â—Ź Introduction and Motivation â—Ź Architecting for Variability and Commonality
  • 3. 3 Software Architecture â—Ź Software architecture deals with the design of the high- level structure of the software â—Ź Assembly of architectural elements in some well-chosen forms to satisfy requirements (including Reliability, Scalability, Portability, etc) â—Ź Software architecture = {Elements, Forms, Rationale/Constraints} â—Ź Software architecture deals with â—Ź abstraction â—Ź decomposition and composition â—Ź styles
  • 4. 4 Architecture of Core Flight software 4 (BSP)
  • 5. 5 Why we need Software Architecture? â—Ź Real-world systems are large and complex â—Ź Need to divide-and-conquer â—Ź Software architecture is used for: â—Ź Distributing work to teams for developing components (in parallel) â—Ź Integrating components â—Ź Planning and defining strategies for software testing â—Ź Understanding the “big-picture” of the system â—Ź Software architecture is for Project Managers, Developers, Testers, Customers (details next slides)
  • 6. 6 Use of Software Architecture for Project Managers â—Ź Managing large projects is a challenging task â—Ź Software architecture can help managers through divide- and-conquer strategy â—Ź Project managers can use Software Architecture for: â—Ź Assigning budget and effort for components â—Ź Coordinating with architects, developers, testers, etc â—Ź Assigning people with the right skills to the right components (e.g., people with device-driver skills to Hardware/OS intensive components) â—Ź Tracking the project progress based on individual components â—Ź Developing a business model or marketing strategy (e.g., selling a part of the system, Open Source, Outsourcing)
  • 7. 7 Use of Software Architecture for Developers and Testers â—Ź Developers should implement individual components based on Software Architecture â—Ź Developers need to understand Software Architecture before making changes to existing implementation â—Ź Testers have to define test-strategy based on Software Architecture, for example: â—Ź Should low-level components be tested first, high-level components be tested first, or a mix â—Ź Testers may have to write mock-test or stubs to unit-test individual components
  • 8. 8 Use of Software Architecture for System Builders â—Ź Software Arch. is needed to compile, link, and produce executables â—Ź Developing Makefiles or build scripts requires sound understanding of your architecture â—Ź You can even generate Makefiles (or build scripts) for each directory if you know your arch. â—Ź Dependency rules are needed to compile the right set of files when source code evolves
  • 9. 9 Architecture vs. (detailed) Design â—Ź Difference lies in your context and how you see â—Ź An architectural diagram in one context could become a design diagram in another context â—Ź For example: â—Ź if you architect a component you may develop architectural diagrams for it â—Ź if the same component is used in another system, then those arch diagrams become design diagrams
  • 10. 10 Architecture vs. (detailed) Design â—Ź Architecture is concerned with global decisions â—Ź Design is concerned with local decisions â—Ź That is, architecture is concerned with the system-level design decisions â—Ź How components fit-together? â—Ź What are the interfaces? â—Ź System-level performance, scalability, security, etc., â—Ź Whereas design is concerned with sub-parts of the system â—Ź How components are designed internally? â—Ź Which algorithms to choose?
  • 11. 11 Software Connectors â—ŹConnectors, for example: â—ŹProcedure Call â—ŹFile â—ŹPipe â—ŹQueue â—ŹSocket â—ŹShared Memory â—ŹConnectors are used for connecting components
  • 12. 12 Components vs. Connectors â—ŹComponents provide application functionality â—Ź Connectors specify the protocol of interaction among components â—Ź Connectors are usually independent of the application domain â—Ź Connectors are often implemented by programming languages or OS
  • 13. 13 (Some) Main Roles of Connectors â—Ź Coordinator â—Ź Wrapper â—Ź Adaptor â—Ź Monitor
  • 14. 14 Coordinator as a Connector â—Ź Let us assume we want to draw a bar chart for some stock data â—Ź Also assume we have two components: â—Ź CollectStockData – collects stock data to a file â—Ź DisplayStockData – draws a graph based on the file â—Ź How do we compose these two components? â—Ź We need a coordinator that invokes: 1. CollectData 2. DisplayData
  • 15. Coordinator as a Connector … void collectStockData(File outputFile, …) { /* Connect to the Stock Server */ … /* Write stock data to the output file */ outputFile.write(…); } void displayStockData(File inputFile, …) { /* Extract data from inputFile */ dataSet = readLines(inputFile) … /* Draw chart using dataSet */ … ui.drawBarChart(dataSet); } void my_main() { /* Collect stock data to a file */ collectStockData(dataFile); /* Display the stock data */ displayStockData(dataFile); } coordinator
  • 16. 16 Wrapper as a Connector â—Ź Let us assume we want to log the important events of the system â—Ź Apache’s Log4j is a popular library for logging â—Ź If components of the system use Log4j directly, there are a few problems: â—Ź Not easy to replace Log4j by another library â—Ź Possibly the layouts of log are different (hard to analyze) â—Ź Solution: Develop a wrapper to Log4j â—Ź This wrapper acts as a connector to the Log4j library
  • 17. Wrapper as a Connector … … import org.apache.log4j.ConsoleAppender; import org.apache.log4j.Level; import org.apache.log4j.Logger; import org.apache.log4j.EnhancedPatternLayout; … /** * This class provides common logger wrapper to facilitate the customized usage * of Apache log4j logger. */ public class LogService { // For current instance (singleton) private static LogService instance = null; // Log4j logger private static Logger logger = null; … Wrapper
  • 18. 18 Adaptor as a Connector â—Ź Adaptors are often used to handle mismatches in interfaces of components â—Ź Enables interaction of independently developed mismatched components â—Ź For example: â—Ź Let Component A writes data to a pipe â—Ź But Component B can read data only from a file â—Ź How can we put A and B to work together? â—Ź Solution: We need a Connector C that reads data from the pipe (until EOF) and write to the file from which B can read
  • 19. Adaptor as a Connector … void collectStockData(PipedWriter pw, …) { /* Connect to the Stock Server */ … /* Write stock data to the pipe */ pw.write(…); } void displayStockData(File inputFile, …) { /* Extract data from inputFile */ dataSet = readLines(inputFile) … /* Draw chart using dataSet */ … ui.drawBarChart(dataSet); } void my_adaptor() { /* Collect stock data to a file */ PipedReader pr; PipedWriter pw; pw.connect(pr); collectStockData(pw); /* read from the pipe and write to a file*/ File dataFile = writeToFile(pr); /* Display the stock data */ displayStockData(dataFile); … Adaptor
  • 20. 20 Monitor as a Connector â—Ź In practice, connectors are also used to monitor the running system â—Ź For example: â—Ź all data written to a socket connector is logged by the write method â—Ź Counts number of write and read calls â—Ź Time of write and read â—Ź This data can be used by the architects/developers for understanding the real- traffic and improve system performance â—Ź Run-time load balancing
  • 21. 21 What’s On The Agenda â—Ź Software Architecture â—Ź Introduction and Motivation â—Ź Architecture vs. Design â—Ź Software Connectors â—Ź Software Architectural Styles â—Ź Introduction and Motivation â—Ź Types of Styles â—Ź Software Architecture Description â—Ź Introduction and Motivation â—Ź Viewpoints, Views, â—Ź Consistency across Views â—Ź Architectural Perspectives and Quality â—Ź Software Architecture for Product Lines â—Ź Introduction and Motivation â—Ź Architecting for Variability and Commonality
  • 22. 22 Architecture Style of Historical Buildings – Some Examples â—Ź Dravidian Architecture characteristics: â—Ź pyramidal towers of colossal height dominating the surrounding landscape for miles around â—Ź the rectangular enclosures one within the other â—Ź the use of the flat roof and the entire absence of the arch or dome; â—Ź dependent on intricate carved stone
  • 23. 23 Families of Dravidian Architecture
  • 24. 24 Composition and Structure of Dravidian Temples 1. The principal part, the actual temple itself, is called the Vimana. It is always square in plan, and surmounted by a pyramidal roof of one or more stories; and it contains the cell in which the image of the god or his emblem is placed. 2. The porches, which always cover and precede the door leading to the cell. 3. Gate-pyramids , which are the principal features in the quadrangular enclosures that surround the more notable temples. 4. Pillared halls -- used for various purposes, and which are the invariable accompaniments of these temples.
  • 25. 25 Mughal Architecture Style – Taj Mahal â—Ź the architectural design of Taj Mahal uses the interlocking arabesque concept: â—Ź each element is complete in itself, yet it integrates perfectly to look as though it is a part of the main structure. â—Ź The corners of the platform are truncated to form an unequal octagon. â—Ź Self-replicating symmetry and geometry of architectural elements are the ruling principles in the design of Taj.
  • 26. 26 Families of Mughal Architecture Style
  • 27. 27 Families of Gothic Architecture
  • 28. 28 Architectural Styles - Benefits â—Ź Explains the nature of components used â—Ź Explains the topology â—Ź way the system (e.g., building) is structured â—Ź Help to build a family of systems ➢Let us learn about Software Architecture Styles
  • 29. 29 Some Software Architectural Styles â—Ź Layer â—Ź Pipe-and-Filter â—Ź Publish-Subscribe â—Ź Implicit-Invocation â—Ź Styles for Net-Centric Systems â—Ź Client-Server â—Ź Peer-to-Peer
  • 30. 30 Layered Style â—Ź The system is organized as a collection of layers based on abstraction levels â—Ź Typically, Components of the lowest-level layer interacts with the underlying OS or Hardware â—Ź Topology: A Layer uses services offered by its adjacent low-level layer (via API) â—Ź (Static) Control-flow is from the top layer to the bottom layer â—Ź At run-time, due to callbacks the control can flow from the bottom layer to the top layer
  • 31. 31 Layered Style - Benefits â—Ź Enables incremental testing from the bottom to top layer â—Ź Plug-out and Plug-in of a layer with a new layer conforming to the same API â—Ź Helpful in producing variants of a product â—Ź Helps to distribute the work to different teams â—Ź Often different teams work on different layers
  • 32. 32 Layered Style - Liabilities â—Ź It is hard to decompose the system into different- levels of abstraction â—Ź What to abstract and what-not-to abstract requires experience and business knowledge â—Ź Also, defining API’s for each layer is challenging â—Ź Especially hiding implementation details at the interface level â—Ź (Some-cases) Performance problems due to indirections â—Ź Implementation might skip layers â—Ź Duplicate or cloned code to escape layer-usage rules â—Ź Exceptions from low-level layers must also be abstracted
  • 33. 33 Pipe-and-Filter Style â—Ź Famous in Unix environment â—Ź find . –name “*.c” | xargs cat | wc –l â—Ź The above instruction count the total number of lines in all c files â—Ź find command list the files with .c extension â—Ź cat command concatenates all files (using xargs) â—Ź wc –l counts the number of lines â—Ź Pipes (|) facilitate the co-ordination of filters (i.e., commands) â—Ź Topology: Upward filter writes to a pipe and downward filter reads from the pipe
  • 35. 35 Pipe-and-Filter Style - Benefits â—Ź Filters are not directly coupled to each other â—Ź Filters can be composed with different filters to produce new configurations â—Ź Helps in producing system variants â—Ź Filters can be tested independently â—Ź Filters can be executed concurrently
  • 36. 36 Pipe-and-Filter Style – Liabilities â—Ź It is hard to share data between non-adjacent filters â—Ź Error handling is very difficult â—Ź If one intermediate filter fails then other filters might get wrong-data â—Ź Not easy to propagate errors upwards â—Ź System could be in trouble if filters disagree on the interaction protocol
  • 37. 37 Publish-Subscribe Arch Style â—Ź Components don’t interact directly â—Ź Components publish messages to a connector (e.g. a message bus) â—Ź Components subscribe to messages of interest to the connector â—Ź The connector delivers corresponding messages to components â—Ź Components often run asynchronously
  • 38. Publish-Subscribe Inter-task Message Router (SW Bus) Transponders Commands Real-time Telemetry (UDP) Comm Cards File downlink (CFDP) Summit Chip Mass Storage System CFDP File Transfer File Manager Local Storage Data Storage Event Services Executive Services Time Services 1553 Bus Support Software Bus Command Ingest Telemetry Output Table Services EDA CMemor yScrubber Self Test Memor yDwel l Instrument Manager Checksum Memor yManager GN&C Applications (4) Mission Apps cFE core App CFS Applications Stored Commanding Software Scheduler Health &Safety Manager House- keeping Limit Checker
  • 39. 39 Publish-Subscribe - Benefits â—Ź Components are not coupled to each other â—Ź New components can be added/removed at run- time â—Ź Components can also dynamically unsubscribe to subscribed messages â—Ź New variants of the system can be produced with different configurations of components â—Ź The connector takes care of delivering messages to components
  • 40. 40 Publish-Subscribe - Liabilities â—Ź There is overhead due to the connector’s routing algorithm â—Ź Actual topology is known only at run-time â—Ź Hard to analyze the implemented system because the control and data-flow information are not easy to track â—Ź The correctness of the connector is very crucial â—Ź If the message bus is not reliable then messages might be delivered to wrong subscribers
  • 41. 41 Implicit Invocation Style â—Ź Components call other components implicitly â—Ź Components register their interest to certain events to other components â—Ź When events happen all interested components (i.e., event listeners) get invoked implicitly â—Ź This style is commonly found in UI â—Ź For example, please call me “if mouse click event happens”
  • 42. 42 Implicit Invocation Style - Benefits â—Ź Components don’t know the identify of components they interact â—Ź A component can be composed with a different component
  • 43. 43 Implicit Invocation Style - Liabilities â—Ź System structure is often not intuitive â—Ź Static analysis of the source code to extract the architecture is very hard due to indirections â—Ź The model is event driven. One event is triggered by the occurrence of another event â—Ź Proving/testing correctness of the system can be hard
  • 44. 44 Arch Styles for Net-Centric systems â—Ź Components of a distributed system often run in different computers â—Ź Components communicate through connectors: â—Ź Remote procedure calls (as in RMI) â—Ź Brokers (as in CORBA) â—Ź Sockets (TCP/UDP)
  • 45. 45 Client-Server Arch. Style â—Ź Two types of components: Client, Server â—Ź Client request the server for its service â—Ź Server give response to the client â—Ź Client and Server can run in different machines asynchronously â—Ź Connectors (e.g., Sockets) help connecting clients to servers
  • 46. 46 Client-Server Arch Style … SAM DsDm SDIF MOC Client OAM c s c s s s s s SVE c c c c c c s s c c s SNI F c c c c c c NCCD S s s s s s s DASs c s s s s s s s c Client-side Socket s Server-side Socket
  • 47. 47 Client-Server Arch. Style - Benefits â—Ź Intuitive structure based on request/response paradigm â—Ź Clear separation of responsibilities among the client and server â—Ź Many clients can use a server â—Ź Client and server can run concurrently
  • 48. 48 Client-Server Arch. Style - Liabilities â—Ź Server must handle heavy traffic (if applicable) â—Ź Also Load balancing is needed â—Ź Additional complexity due to: â—Ź Thread creation/termination per connection , or â—Ź Thread pool management, or â—Ź Managing queue of requests from clients â—Ź Must be prepared to handle network failures
  • 49. 49 Composing Styles â—Ź Often large systems are made of many different styles â—Ź For example: â—Ź the high-level structure could be a layer, and â—Ź components within a layer could follow publish/subscribe architecture style â—Ź two adjacent layers could interact through a pipe â—Ź Styles can be safely composed as long as they don’t violate style constraints
  • 50. 50 Composing Styles … â—Ź In practice, often performance is the main criteria for â—Ź selecting the styles â—Ź composing the styles â—Ź Architects typically perform a trade-off analysis or based on their experience select and compose styles â—Ź Select and compose styles based on quality properties (e.g., Usability, Performance) for your system
  • 51. 53 What’s On The Agenda â—Ź Software Architecture â—Ź Introduction and Motivation â—Ź Architecture vs. Design â—Ź Software Connectors â—Ź Software Architectural Styles â—Ź Introduction and Motivation â—Ź Types of Styles â—Ź Software Architecture Description â—Ź Introduction and Motivation â—Ź Viewpoints, Views, â—Ź Consistency across Views â—Ź Architectural Perspectives and Quality â—Ź Software Architecture for Product Lines â—Ź Introduction and Motivation â—Ź Architecting for Variability and Commonality
  • 52. 54 Software Architecture Description â—Ź There is no common consensus on what an architecture description (AD) should contain â—Ź Typically, AD contains system-level design decisions that are of concern to the whole system and everyone should be aware of â—Ź AD should contain, for example: â—Ź High-level components, â—Ź Connectors that connect the components â—Ź Protocol of interactions among components â—Ź Error handling strategy – how exceptions are handled? â—Ź Concurrency model – how multiple clients are handled by a single server? â—Ź Data or information flow – how data/information is passed between components?
  • 53. 55 Describing Software Architecture using Views â—Ź How to best describe Software Architecture is a topic of on-going R&D â—Ź In literature, views are used to describe Software Architecture â—Ź Each view address one concern, for example: â—Ź Structural view shows the decomposition of system â—Ź Behavioral view shows how components interact at run-time â—Ź Deployment view shows how components are assigned to hardware elements
  • 54. 56 Viewpoints and Views (IEEE 1471 Standard Defn) â—Ź A view is a representation of all or part of an architecture, from the perspective of one or more concerns which are held by one or more of its stakeholders. â—Ź A viewpoint is a collection of patterns, templates and conventions for constructing one type of view.
  • 55. Viewpoints, Views, and Architectural Description Viewpoint View Architectural Description defines 0..n 1 .. n •An architectural description is a collection of one or more views. •A viewpoint is used to define (the structure and content of) zero or more views. •The structure and content of a particular view is defined by exactly one viewpoint.
  • 56. 58 Some Approaches for Describing Software Architecture â—ŹKruchten “4 + 1” View â—ŹSiemens View â—ŹSEI View â—ŹPhilips View â—ŹRozanski and Woods View
  • 57. 59 Kruchten 4 + 1 View Viewpoint Definition Logical The logical representation of the system’s functional structure. Process The concurrency and synchronization aspects of the architecture. Development The design-time software structure, identifying modules, and subsystems. Physical The identification of the nodes that the system’s software will be executed on and the mapping of other architectural elements to these nodes. Scenarios (+1) A set of functional usage scenarios to illustrate how the views work together. As a driver to discover architectural elements during the architectural design.
  • 58. 60 Siemens View Viewpoint Definition Conceptual The conceptual functional structure of the system that defines a set of conceptual components linked by a set of connectors. Module The concrete structure of the subsystems and modules that will be realized in the system, the interfaces exposed by the modules, the intermodule dependencies, and any layering constraints in the structure. Execution The runtime structure of the system in terms of processes, threads, interprocess communication elements, and so on along with a mapping of modules to runtime elements. Code The design-time layout of the system as source code and the intermediate and delivered binary elements created from it.
  • 59. 61 SEI View Viewtype Definition Component and Connector It is concerned with the sytem’s runtime functional elements, their behaviors, and their interactions. The following styles defined for this viewtype all relate to commonly occurring runtime system organizations: • Pipe-and-Filter • Shared-Data • Publish-Subscribe • Client-Server • Peer-to-Peer • Communicating-Processes
  • 60. 62 SEI View… Viewtype Definition Module The module viewtype is concerned with the how the software comprising the system is structured as a set of implementation (code) units. The following styles are defined for the Module viewtype: • Uses: for capturing inter-module usage dependencies • Generalization: for capturing commonality and variation (inheritance) relationships between modules • Decomposition: for specifying how modules are composed from simpler elements • Layered: for specifying how modules are arranged in layers according to their level of abstraction
  • 61. 63 SEI View … Viewtype Definition Allocation It is concerned with how relationships between the different parts of the system and different aspects of their environment are captured. The following styles are defined for this viewtype: • Deployment: for specifying how software elements are mapped to elements of the deployment environment • Implementation: for specifying how software modules are mapped to the development environment (such as their location in a codebase) • Work assignment: for mapping software modules to those responsible for creating, testing, and deploying them.
  • 62. 64 Philips View (BAPO) Viewpoint Primary Focus Business Goals of the business Architecture Decisions based on Business Goals Process Policies and Planning. E.g., change management, Version Control, Project plans Organization Structure of development teams, and reporting hierarchy.
  • 64. Rozanksi and Woods View Functional Viewpoint Information Viewpoint Concurrency Viewpoint Development Viewpoint Deployment Viewpoint Operational Viewpoint The Functional, Information, and Concurrency viewpoints characterize the fundamental organization of the system. The Development viewpoint exists to support the system’s construction. The Deployment and Operational viewpoints characterize the system once in its live environment.
  • 65. 67 Rozanksi and Woods View … Viewpoint Definition Information Describes the way that the architecture stores, manipulates, manages, and distributes information. The aim of this viewpoint is to identify structure, ownership, latency, references, and data migration. Operational Describes how the system will be operated, administered, and supported when it is running in its production environment. Installing, managing, and operating the system are the concerns of interest to this viewpoint.
  • 67. 69 Functional View (some examples) â—Ź Cranefoot is a tool for visualizing Pedigrees (family history tree) used in genetic studies
  • 70. 72 Execution View of Cranefoot Cranefoot runs on a single thread in a single machine – thus no separate process view was documented
  • 71. 73 Consistency across Views â—Ź Views helped us with the partitioning the representation of our architecture â—Ź But, the challenge is how to ensure consistency between them â—Ź How to ensure that the structures, features, and elements that appear in one view are compatible and in alignment with the content of other views?
  • 72. 74 Consistency across Views … â—Ź Consistency is a vital characteristics of our Architecture Description â—Ź Without consistency, the system: â—Ź will not work properly â—Ź will not achieve its design goals â—Ź may even be impossible to build â—Ź Arguably, no tools automate consistency between views â—Ź Ensuring consistency comes down to the skill, thoroughness, and diligence of the architect â—Ź Checklists could help during reviews (coming next)
  • 73. 75 Functional and Concurrency View Consistency – Sample Checklist â—Ź Goal: To ensure that the functional elements are all mapped to a task that will allow them to execute and the inter-element interactions are supported by the IPC mechanisms if required ➢Is every functional element in the Functional view mapped to a concurrent element (a process or thread) responsible for its execution in the Concurrency view?
  • 74. 76 Functional and Deployment View Consistency – Sample Checklist â—Ź Goal: To ensure that each of the functional elements is correctly mapped to its deployment environment. ➢Has each functional element been mapped to a processing node to allow it to be executed? ➢Where functional elements are hosted on different nodes, do the network models allow the required element interactions to occur?
  • 75. 77 Functional and Deployment View Consistency – Sample Checklist … ➢Are functional elements that need to interact extensively hosted as close together as possible? ➢Are the specified network connections sufficient for the needs of the interelement interactions that will be carried over them (in terms of capacity, reliability, security, and so on)? ➢Is the hardware specified in the Deployment view the most efficient solution for hosting the specified functional elements?
  • 76. 78 Functional and Operational View Consistency – Sample Checklist â—Ź Goal: To ensure that each of the specified functional elements can be installed, used, operated, and supported. ➢Does the Operational view make it clear how every functional element will be installed? ➢Does the Operational view explain how each functional element will be monitored and controlled in the production environment?
  • 77. 79 Information and Concurrency view Consistency â—Ź Goal: To ensure that the concurrency structure of the system does not cause data access problems and that the proposed information structure is compatible with the concurrency structure. ➢Does the concurrency design imply concurrent access to any of the system’s data elements? â—Ź If so, have the data elements been protected from concurrent access problems? ➢If functional elements that share data elements are packaged into different OS processes, has a suitable inter-process data-sharing mechanism been defined?
  • 78. 80 Information and Deployment View Consistency â—Ź Goal: To ensure that the proposed deployment environment provides the resources required to support the defined information structure. ➢ Does the Deployment view include enough storage to support the information specified by the Information view? ➢ If large volumes of information need to be moved, is sufficient bandwidth available so that this can be achieved without performance issues? ➢ Does the Deployment view reflect the requirements for backup and recovery as addressed by the Info. View?
  • 79. 81 Concurrency and Development view Consistency â—Ź Goal: To ensure that the concurrency structure specified in the concurrency view can be built and tested in the development environment specified by the Development view. ➢ If the concurrency structure is complex, are sufficient design patterns specified in the Development view to guide its implementation? ➢ Does the code structure defined in the Development view support the packaging of the system’s functional elements into the operating system processes specified by the Concurrency view? ➢ Does the test approach defined in the Development view support the concurrency structure specified in the Concurrency view?
  • 80. 82 Architectural Perspectives â—Ź A viewpoint advises on how to create and describe a particular type of architectural structure (e.g., Concurrency, Information) â—Ź A perspective provides advice relating to the cross view concerns of a particular quality property (e.g., Security, Performance) â—Ź Architectural perspectives provide a framework for structuring knowledge about how to design systems to achieve quality
  • 81. 83 Examples of Applying Perspectives to Views Security Performance Availability Evolution OperationalConcurrencyInformationFunctional PERSPECTIVES VIEWS Information Security (Access control) Functional Evolution (extension points, flexible interfaces) Concurrency Performance (shared resources, blocking, queuing)
  • 82. 84 Structure of a Perspective â—Ź the Concerns that the perspective is addressing â—Ź the Applicability of the perspective to the different possible architectural views â—Ź a set of possible Activities for achieving the quality property â—Ź a set of proven Architectural Tactics or strategies â—Ź a list of common Problems and Pitfalls â—Ź a Checklist to ensure nothing has been forgotten ➢Let us see an example of Security perspective
  • 83. 85 Concerns of Security Persp. â—Ź Policy (the actions that difference principals can perform on sensitive resources) â—Ź Threats (the security threats that the system faces) â—Ź Governance (the mechanisms for implementing the policy securely, including authentication, authorization, confidentiality, integrity and accountability) â—Ź Availability (ensuring that attackers cannot prevent access to a system) â—Ź Detection and Recovery from Breach (allowing recovery when security fails)
  • 84. 86 Views applicable to Security â—Ź Deployment view â—Ź Adding security related hardware and software â—Ź Development view â—Ź Setting system wide security related standards â—Ź Functional view â—Ź Partitioning the system differently to allow controlled access to sensitive parts
  • 85. 87 Activities for Security â—Ź Identification of sensitive resources â—Ź Definition of a security policy â—Ź Creation of a threat model â—Ź Design of a security implementation â—Ź Assessment of security risk
  • 86. 88 Architectural tactics for Security â—Ź Application of recognized security principles: â—Ź Example: least privilege, auditing â—Ź Principal identification mechanisms â—Ź Access control mechanisms â—Ź Information protection mechanisms â—Ź Provision of security administration â—Ź Use of 3rd party security technology
  • 87. 89 Problems and Pitfalls of Security â—Ź Complex security policies â—Ź Use of unproven security technology â—Ź Not designing for secure failure conditions â—Ź Not providing effective admin facilities â—Ź Leaving security as an afterthought â—Ź Use of ad-hoc technology to enforce security â—Ź Driving the process by technology choice rather than security threats
  • 88. 90 Checklist for Security â—Ź Is there a clear policy that defines which principals are allowed to perform which operations on which resources? â—Ź Is the security policy as simple as possible? â—Ź Have security requirements been reviewed with external experts? â—Ź Has each threat identified in the threat model been addressed to the extent necessary? â—Ź …
  • 89. 91 Core set of Perspectives Perspective Purpose Security Ensure who can perform what actions on resources Performance and Scalability Ensure the system’s ability to predictably execute within its mandated performance req. and to handle increasing processing volumes Availability and Resilience Ensure the system’s ability to be fully or partly operational. Effectively handle failures. Evolution Ensure the system’s flexibility to change
  • 90. 92 Other Perspectives Perspective Purpose Internationalization Ensure the system’s independence from any particular language, country or cultural group. Accessibility Ensure the ability of the system to be used by people with disabilities. Usability Ensure that people who interact with the system can easily work effectively. Regulation Ensure the ability of the system to comply with local and international laws, regulations, policies, etc., Development Resource Ensure that the system can be designed, built, and operated within constraints around people, budget. Licensing Ensure that the system has appropriate licensing mechanism in place according to marketing plans.
  • 91. Using Perspectives Analyse and Understand Key requirements Create a Candidate Architecture Apply Perspectives Modify Architecture Perform “Formal” Architectural Evaluation (e.g., Scenario-based methods ATAM, SAAM) [Unacceptable properties] [acceptable properties]
  • 92. 94 What’s On The Agenda â—Ź Software Architecture â—Ź Introduction and Motivation â—Ź Architecture vs. Design â—Ź Software Connectors â—Ź Software Architectural Styles â—Ź Introduction and Motivation â—Ź Types of Styles â—Ź Software Architecture Description â—Ź Introduction and Motivation â—Ź Viewpoints, Views, â—Ź Consistency across Views â—Ź Architectural Perspectives and Quality â—Ź Software Architecture for Product Lines â—Ź Introduction and Motivation â—Ź Architecting for Variability and Commonality
  • 96. 98 SPL Definition â—Ź A software product line is a set of software-intensive systems sharing a common, managed set of features that satisfy the specific needs of a particular market segment or mission and that are developed from a common set of core assets in a prescribed way. â—Ź SPL â—Ź take economic advantage of commonality â—Ź bound variation â—Ź PRODUCT LINES = STRATEGIC REUSE
  • 98. 100 Motivation for SPL â—Ź Achieve large scale productivity gains â—Ź Improve time to market â—Ź Enable mass customization â—Ź Get control of diverse product configurations â—Ź Improve product quality â—Ź Increase predictability of cost, schedule, and quality ➢The product line architecture is central to success
  • 99. 101 Architecting for SPL â—Ź Two of the fundamental needs in defining an architecture for a product line are â—Ź to be able to generalize or abstract from the individual products to capture the important aspects of the product line â—Ź to be able to instantiate an individual product architecture from the product line architecture â—Ź Having a product line implies having a generic architecture from which the individual product architectures can be derived in some manner
  • 100. 102 Architecting for SPL … â—Ź Use Architectural styles to handle variation â—Ź For example, a Pipe-and-Filter style can be used to produce different product instances â—Ź Select Filters of interest and produce new config. â—Ź Use a Layered architectural style to “hide” variations in OS and Hardware â—Ź Important to define Abstract APIs with alternative implementations â—Ź Use a Publish-Subscribe style for: â—Ź Substituting various publishers and subscribers â—Ź Plug-in new publishers and subscribers â—Ź Run-time adaptation
  • 101. Architecture-level Variability Inter-task Message Router (SW Bus) Transponders Commands Real-time Telemetry (UDP) Comm Cards File downlink (CFDP) Summit Chip Mass Storage System CFDP File Transfer File Manager Local Storage Data Storage Event Services Executive Services Time Services 1553 Bus Support Software Bus Command Ingest Telemetry Output Table Services EDA CMemor yScrubber Self Test Memor yDwel l Instrument Manager Checksum Memor yManager GN&C Applications (4) Mission Apps cFE core App CFS Applications Stored Commanding Software Scheduler Health &Safety Manager House- keeping Limit Checker
  • 102. 104 Variation within Components â—Ź Configurable component (e.g., Properties, #ifdef) â—Ź Variation is supported within the component â—Ź Select appropriate values for config. parameters â—Ź Enable/disable parts of code using config. param. â—Ź Extensible component (e.g., Inheritance) â—Ź Consists of an extensible base â—Ź Variable parts are separate sub-components â—Ź Generic and specific functionality are separated â—Ź Abstract component (e.g., Java Interface) â—Ź Only the interface is provided â—Ź Different products must provide own implementation â—Ź Suitable when implementation differs a lot
  • 103. 105 Example: Variation within OS Abstraction Layer â—Ź Software Bus requires a communication mechanism internally â—Ź The OS abstraction layer offers two implementations: â—Ź Socket, or â—Ź Queue â—Ź At preprocessing time this variation point must be resolved â—Ź Software Bus uses the same API for both communication mechanisms
  • 104. Variation within OS Abstraction Layer… /**************************************************************************************** MESSAGE QUEUE API ****************************************************************************************/ #ifdef OSAL_SOCKET_QUEUE int32 OS_QueueCreate (uint32 *queue_id, const char *queue_name, uint32 queue_depth uint32 data_size, uint32 flags) { … socket(AF_INET, SOCK_DGRAM, 0); … } #else /* ---------------------- POSIX MESSAGE QUEUE IMPLEMENTATION -------------------- */ int32 OS_QueueCreate (uint32 *queue_id, const char *queue_name, uint32 queue_depth uint32 data_size, uint32 flags) { …. mq_open(name, O_CREAT | O_RDWR, …); }
  • 105. 107 References/Further reading 1. P. Kruchten. Architectural Blueprints – The “4+1” View Model of the Software Architecture. IEEE Software 12(6), Nov 1995, pp. 42-50. 1. D. Ganesan. The Software Architecture of Cranefoot. - An independent analysis by Fraunhofer, Maryland, USA, 2009. 1. D. Ganesan, M. Lindvall, C. Ackermann, D. McComas, and M. Bartholomew. Verifying Architectural Design Rules of the Flight Software Product Line. IEEE Proceedings of Software Product Line Conference, 2009. 1. N. Rozanski, E. Woods. Software Systems Architecture. Addison-Wesley. 1. R. N. Taylor, N. Medvidovic, E. M. Dashofy. Software Architecture. Foundations, Theory, and Practice. Addison-Wesley. 1. M. Shaw, D. Garlan. Software Architecture – Perspectives on an Emerging Discipline. Prentice Hall, 1996. 1. F. Buschmann et al. Pattern-Oriented Software Architecture. Addison-Wesley, 2001. 1. J. Mehdi, A. Ran, and F. van der Linden. Software Architecture for Product Families: Principles and Practice. Addison-Wesley, 2000.
  • 106. 108 References/ Further Reading 9. C. Hofmeister et al. Generalizing a Model of Software Architecture Design from Five Industrial Approaches. IEEE Proceedings of Working Conference on Software Architecture, 2005.