Software Architecture

Slides:



Advertisements
Similar presentations
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 9 Distributed Systems Architectures Slide 1 1 Chapter 9 Distributed Systems Architectures.
Advertisements

Lecturer: Sebastian Coope Ashton Building, Room G.18 COMP 201 web-page: Lecture.
Technical Architectures
Managing Data Resources
Architectural Styles. Definitions of Architectural Style  Definition. An architectural style is a named collection of architectural design decisions.
Distributed Systems Architectures
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 11 Slide 1 Architectural Design.
Establishing the overall structure of a software system
Ch 12 Distributed Systems Architectures
Architectural Design, Distributed Systems Architectures
Course Instructor: Aisha Azeem
Architectural Design Establishing the overall structure of a software system Objectives To introduce architectural design and to discuss its importance.
Chapter 6: Architectural Design
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 12 Slide 1 Distributed Systems Design 1.
System Design & Software Architecture
Introduction to Databases Transparencies 1. ©Pearson Education 2009 Objectives Common uses of database systems. Meaning of the term database. Meaning.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 11 Slide 1 Architectural Design.
Chapter 10 Architectural Design
The Design Discipline.
Chapter 7: Architecture Design Omar Meqdadi SE 273 Lecture 7 Department of Computer Science and Software Engineering University of Wisconsin-Platteville.
Software Architecture
©Ian Sommerville 2006Software Engineering, 8th edition. Chapter 12 Slide 1 Distributed Systems Architectures.
©Ian Sommerville 1995 Software Engineering, 5th edition. Chapter 13Slide 1 Architectural Design u Establishing the overall structure of a software system.
©Ian Sommerville 2000 Software Engineering, 6th edition. Chapter 10Slide 1 Chapter 10 Architectural Design.
1 CMPT 275 High Level Design Phase Architecture. Janice Regan, Objectives of Design  The design phase takes the results of the requirements analysis.
Architectural Design, Distributed Systems Architectures
An Introduction to Software Architecture
Architectural Design portions ©Ian Sommerville 1995 Establishing the overall structure of a software system.
SOFTWARE DESIGN AND ARCHITECTURE LECTURE 07. Review Architectural Representation – Using UML – Using ADL.
Architectural Design To explain the advantages and disadvantages of different distributed systems architectures To discuss client-server and distributed.
©Ian Sommerville 2000 Software Engineering, 6th edition. Chapter 10Slide 1 Architectural Design l Establishing the overall structure of a software system.
Architecture styles Pipes and filters Object-oriented design Implicit invocation Layering Repositories.
CS4311 Spring 2011 Software Architecture Dr. Guoqiang Hu Department of Computer Science UTEP.
Basic Concepts Software Architecture. What is Software Architecture? Definition: – A software architecture is the set of principal design decisions about.
Architectural Design lecture 10. Topics covered Architectural design decisions System organisation Control styles Reference architectures.
Software Architectural Styles Andrew Midwinter, Mark Mullen, Kevin Wong, Matt Jones 1.
©Ian Sommerville 2000 Software Engineering, 6th edition. Chapter 10Slide 1 Architectural Design l Establishing the overall structure of a software system.
Architectural Design Yonsei University 2 nd Semester, 2014 Sanghyun Park.
CS.436 Software Engineering By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 8 Architectural Design Slide 1 1 Chapter 8 Architectural Design.
 Repository Model  Client-Server Model  Layered Model  Modular decomposition styles  Object Models  Function Oriented Pipelining  Control Styles.
Unit 2 Architectural Styles and Case Studies | Website for Students | VTU NOTES | QUESTION PAPERS | NEWS | RESULTS 1.
Chapter 2 Database System Concepts and Architecture Dr. Bernard Chen Ph.D. University of Central Arkansas.
1 CMPT 275 High Level Design Phase Modularization.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 11 Slide 1 Architectural Design.
Chapter 7: Architectural Design Chapter 11 in textbook 1.
CSC480 Software Engineering Lecture 10 September 25, 2002.
©Ian Sommerville, Robin Abraham 2004CS 361, Summer 2004 Slide 1 Architectural Design.
Lecture VIII: Software Architecture
Basic Concepts and Definitions
Chapter : 9 Architectural Design
CS223: Software Engineering
Slide 1 Chapter 8 Architectural Design. Slide 2 Topics covered l System structuring l Control models l Modular decomposition l Domain-specific architectures.
Basic Concepts of Software Architecture. What is Software Architecture? Definition: – A software system’s architecture is the set of principal design.
System Architecture CS 560. Project Design The requirements describe the function of a system as seen by the client. The software team must design a system.
©Ian Sommerville 2000 Software Engineering, 6th edition. Chapter 10Slide 1 Chapter 5:Architectural Design l Establishing the overall structure of a software.
Distributed Systems Architectures Chapter 12. Objectives  To explain the advantages and disadvantages of different distributed systems architectures.
Distributed Systems Architectures. Topics covered l Client-server architectures l Distributed object architectures l Inter-organisational computing.
Software architecture
SOFTWARE DESIGN AND ARCHITECTURE
Software Design and Architecture
Part 3 Design What does design mean in different fields?
CHAPTER 2 CREATING AN ARCHITECTURAL DESIGN.
Software Architecture
Architectural Design.
Chapter 6 – Architectural Design
An Introduction to Software Architecture
Chapter 5 Architectural Design.
Chapter 6: Architectural Design
Chapter 6 – Architectural Design
Presentation transcript:

Software Architecture CS 4311

Architecture Design at the highest level Example: bridge architectures Cable-stayed Beam Suspension

Why do civil engineers talk about bridge architectures? Design at the highest level Example: bridge architectures Arch Cable-stayed Beam Suspension

What is architecture? Dictionary definitions: archangel, archenemy, archduke, archbishop matriarch, patriarch, monarch Arch as prefix or suffix: main, chief, principal, most important, highest, fundamental, basic, extreme or most characteristic, ruler, leader

Architecture The art and science of designing and erecting buildings Fundamental underlying design of buildings Style and method of design and construction of buildings Buildings and other structures

What is software architecture? Framework Mechanism Way Shape Form Means Organization Arrangement The Big Picture !

Software Architecture the structure or structures of the system software components externally visible properties of those components the relationships between them the set of principle design decisions made about a software system.

What design decision? System structure Functional behavior Interaction Nonfunctional properties Implementation System goals, Stakeholders, Nontechnical considerations

Independent Components Broadcasts Client-server Event driven Components register for an event. System invokes all registered components when event happens. Example: Java AWT Dynamic, responsibility with event handler, not event generator. Can be hard to test/debug.

Virtual Machines Interpreters: Examples: Program to be executed Interpreter: simulate instructions in program State: State of program, state of interpreter Examples: JVM Command language processors

Repositories Central Data store + operations {store, retrieve, update} Traditional: transactions trigger processing Blackboard: Central store controls processing Processes write to central store (knowledge sources) Processes respond to changes in the store

Layered Architecture Layers are hierarchical Each layer provides services to the outer layer which is a client to the inner layer Layers can have access to adjacent layers (direct access only) The design includes how each pair of layers interact (protocols) Layered architectures are often used for interactive information services

Example Layered security architecture Cryptography File interface Key management User

Advantages and Drawbacks + Each layer can be seen as a higher level of abstraction + A change on one layer affects only layers interacting with the changed layer + Clearly favors reuse - Layers are not always obvious when looking at the requirements - Performance may suffer from the extra coordination among the layers

Layered Architectures in Interactive Information Systems Browsers Presentation Web Server Application Control and Coordination App Server Domain Services and Information Db Server Legacy Database Services

Characteristic Object Roles Windows and Widgets Presentation Interfacers Events Coordinators, and (application) controllers Results Application Services Messages Results Information holders, service providers, Structures, coordinators, and domain controllers Domain Services Messages Results Technical Services Interfacers

Locating Objects in Layers Once we have agreed on a layered architecture, we need to identify objects (classes) in layers One approach is to use Class-Responsibility-Collaboration -objects collaborates mostly within their layers -client objects will tend to be in an outer layer (requests go inside) -information goes outside

Process Control Process maintains setpoint Control based on Examples: input variables (feedforward) Output variables (feedback) Examples: Thermostat controlled heater “smart” stock trader

Architecture Elements Components Connectors Configuration Topologies Models

Components Elements that encapsulate processing and data in a system’s architecture are referred to as software components. An architectural entity that encapsulates a subset of the system’s functionality and/or data, restricts access to that subset via an explicitly defined interface, and had explicitly defined dependencies on its required execution context.

Connector Elements that are tasked with effecting and regulating interactions among components. Application independent.

Configuration Topology A set of specific associations between the components and connectors of a software system’s architecture.

Models An artifact that captures some or all of the design decisions that comprise a system’s architecture. Architectural modeling is the reification and documentation of those design decisions. Different models: structural vs. behavioral static vs. dynamic scope

Architectural Styles A named collection of architectural design decisions that: are applicable in a given development context, constrain architectural design decisions that are specific to a particular system with that context, and elicit beneficial qualities in each resulting system. Not about: specific systems, components, interaction mechanisms, or configurations.

An Architectural Style Example Physically separate the software components used to request services from the components that provide the services, to allow for proper distribution and scaling up, both in the number of service providers and service requesters. Make the service providers unaware of the requesters’ identity to allow the providers to service transparently many, possibly changing requestors. Insulate the requesters from one another to allow for their independent addition, removal, and modification. Make the requesters dependent only on the service providers. Allow for multiple service providers to emerge dynamically to off-load the existing providers should the demand for services increase above a given threshold.

Architectural Styles Remarks: Each style has its own advantages and drawbacks An application may require several architectural views Choosing the right views is a key factor in having a good design

Advantages of Architectural Styles Each combination of styles emphasizes one or more of the quality attributes below: Usability Availability Security Performance Maintainability Flexibility Portability

Example Software Architectures Batch Sequential Blackboard Client Server Database-centric Distributed Computing Event driven Interpreter Monolithic application Peer-to-peer Pipe and Filter Plug-in Service-oriented Search-oriented Space-based Shared nothing Three-tier model Rule evaluation

Assignment: Base Groups Each teams has until next class to prepare a 3 minute description of the provided architecture You will present next class What is it What problem does it solve How does it solve the problem Who are the actors How do they relate to each other You will need to be efficient to cover the architecture in 3 minutes Send Aditi 2 or 3 powerpoint slides by 5pm Wednesday INCLUDE YOUR SOURCES

Example Software Architectures Team 1 Blackboard Team 2 Interpreter Team 3 Plug-in Team 4 Search-oriented Team 5 Space-based Team 6 Shared nothing Team 7 Publisher-subscriber Team 8 Rule evaluation

Batch Sequential Architecture A series of dedicated and independent components that transforms data in a sequential manner (Each component needs to finish its task before the next one can start).

Batch Sequential Architecture Solve complex task Divide complex tasks into several easier tasks. Modifiability/Maintainability Easy to change/fix the behavior of a component. Reusability By only changing the components that interact with the environment the system can work on different structures. Flexibility Additional components are easy to integrate.

Batch Sequential Architecture Actors The actors consist of the independent components (programs) that run in sequence to achieve the ultimate desired output of the system. Each components is responsible for a particular task and supplies the next component with the intermediate data once it has completed its task. How do they relate to each other? They are related to each other by the data that they each transform.

Batch Sequential Architecture *Example: Compiler *Software Design Methodology, By Hong Zhu © 2005

Client-Server Architecture Application context: Clients request services from a server Centralization of computation and data at the server Separation of user interface tasks from computation and data management and storage For examples: Websites, etc.

Client Server Architecture Example:

Database-Centric Architecture Critical databases applications always need a global transaction monitor. can significantly reduce performance and scalability. Architecture solves data management and processing of it. Computes all the data to a single place, in this case the database.

Actors and their roles Benefits: DBMS SERVER 1 SERVER 2 Client 1 Client 3 Client 4 Client 6 Client 2 Client 5 Benefits: Reduces amount of code, development time, network traffic, complexity of applications.

Distributed Computing Architecture Also known as grid computing. Makes use of the hardware on several computers. Primarily used to solve those problems that require exceptionally heavy computation. SETI@Home was the first project that demonstrated the feasibility of distributed computing to solve these problems. Indeed, this was one of the primary goals of SETI@Home. The specific problem SETI@Home is used for is to detect intelligent life outside of Earth.

Distributed Computing Architecture The software written for SETI@Home requires 2 components: Central server software manages the distribution of data across personal computers and the collection of analyzed data. Personal computer software performs analysis and monitors processor usage, ensuring that analysis is done only when the processor is not otherwise needed.

Event Driven Architecture Components in the system react to certain events. For example State changes I/O events Creates responsiveness in a changing environment Actors Agents: components in a system that generate events Sinks: event consumers Responsibility of applying action as soon as event is present May act as a filter to another component May provide an action based the given event

Event Driven Architecture Characteristics Facilitates responsiveness Works great in un-normalized unpredictable environments Event flow Sensing of fact Technical representation in the form of an event Reaction(s) to set event Example Email application displays a message stating that a new e-mail has been received

Event Driven Architecture Agent Sink 1 Sink 2 Sink 3 Sink n-1 Sink n event action transformation

Monolithic Architecture Single-Tier Architecture Concept of having user interface and application of data access in one single program. Only application is accountable for computations Simplest software configuration No modularity Not a typical Software Engineering Concept http://publib.boulder.ibm.com/infocenter/discover/v8r4/index.jsp?topic=/com.ibm.discovery.ds.overview.doc/c_UG_Single_Tier_Architectures.htm http://wiki.answers.com/Q/What_is_single-tier_architecture 45

Why Monolithic Architecture? Low Cost Less Complex No need to develop external computational or processing modules Simple and Quick design Single independent application No need for future expansion of software Not easily maintained

Peer-to-Peer Architecture A type of architecture in which each class has equivalent capabilities and responsibilities A class can collaborate with any other class and vice versa Every class has access to the resources needed Every class gives access to all its resources No Super-classes Every class has access to the resources needed to fulfill its responsibilities and at the same time gives access to all of its resources to all other classes 47

Peer-to-Peer Architecture Advantages: Decentralized computing with flow of control and resources distributed among peers Highly robust in the face of failure Scalable in terms of access to resources and computing power Cautions: When information retrieval is time critical Security

Pipe and Filter This is an architecture composed of filters and pipes: A filter is a program that reads a stream and writes a stream A pipe is middle where that directs the output stream of one program to the input stream of another Transformed Data Transformed Data Input Data Filter Filter Filter

Pipe and Filter This is an architecture composed of filters and pipes: A filter is a program that reads a stream and writes a stream A pipe is middle where that directs the output stream of one program to the input stream of another Useful when you have common stream processing programs that can be reused The cost is that a lot of I/O processing is duplicated (e.g., parsing the data)

Example Pipe and Filter Example: Unix shell scripts ccl1 fred.txt | ccp0 | ccp1 | ccp2 > fred.o | is the pipe operator Read from the standard output of program to left Write to standard input of program to right

Pipe and Filter Components are isolated Easy to understand and reuse filters Evolution is easy: replace filter Allows concurrent execution May be easy to analyze (analyze each filter for throughput, accuracy) Batch or stream, not interactive Replication of effort (reading, writing, parsing)

Service-Oriented Architecture (SOA) Problem Client needs access to multiple features however the client shouldn’t know how those features are implemented SOA: Provides access to multiple components or functions Client doesn‘t know what components or how functionality is implemented

SOA Solve the Problem Actors Provides an interface that hides the components and gives the client a single access point. Actors Client Components

Three-Tier Architecture client-server architecture Three different tier Presentation Input/ output Business Data processing Data Access Read/Write

Three-Tier Advantages Highly cohesive and lowly coupled Allows change in modules with out effect on the other tiers Encapsulates tasks