sa 008 architecture_views

24
Vakgroep Informatietechnologie – IBCN Software Architecture Prof.Dr.ir. F. Gielen Architectural Views

Upload: frank-gielen

Post on 25-Jun-2015

459 views

Category:

Technology


0 download

TRANSCRIPT

Page 1: Sa 008 architecture_views

Vakgroep Informatietechnologie – IBCN

Software Architecture

Prof.Dr.ir. F. Gielen

Architectural Views

Page 2: Sa 008 architecture_views

Vakgroep Informatietechnologie – Onderzoeksgroep IBCN p. 2

Software Architecture Definition

The Software Architecture of a program or computing system is the structure or structures of the system, which comprises software elements, the external visible properties of those elements

and the relationships among them.

Page 3: Sa 008 architecture_views

Where do views come from ?

A software architecture is multi-dimensional & complex entity that cannot be described in a simple one-dimensional fashion.

To communicate meaningfully about an architecture, we must make clear which structure or structures we are discussing at the moment - which view we are taking of the architecture.

Vakgroep Informatietechnologie – Onderzoeksgroep IBCN p. 3

Page 4: Sa 008 architecture_views

Vakgroep Informatietechnologie – Onderzoeksgroep IBCN p. 4

Architectural views – Ph.Kruchten

Designview

Component view

Use caseview

Processview

Deployment view

End user - Functionality - Vocabulary

Programmers - Software management

Analysts/Testers - Behavior

System integrators - Performance - Scalability - Throughput

System engineering - System topology - Delivery and installation - Communication

A view is a set of coherent architectural elements.

Page 5: Sa 008 architecture_views

Architecture Documentation Challenges

How do you decide which architectural views to document?

What information do you record about an architectural view beyond the box-and-line diagram?

How do you specify an architectural element's software interface? What information do you record?

How do you specify an element's behavior? What notations are available for documenting a view,

an interface or behavior?

Vakgroep Informatietechnologie – Onderzoeksgroep IBCN p. 5

Page 6: Sa 008 architecture_views

Vakgroep Informatietechnologie – Onderzoeksgroep IBCN p. 6

Architecture Description Languages

Software

Architecture

Requirements

UML

An ADL is a language that provides features for modelling a software system’s conceptual architecture.

Page 7: Sa 008 architecture_views

Vakgroep Informatietechnologie – Onderzoeksgroep IBCN p. 7

Architecture Structures

STATIC view : What is the structure of the system ? What is the primary functional responsibility assigned to each structure? What other software elements is a module allowed to use? What other software does it actually use?

DYNAMIC view: What is the runtime behavior of the system ? What are the major components ? How do they interact , communicate ? What are the major shared data stores? Which parts of the system are

replicated? How does data flow or progress through the system? What are the system states ? What parts of the system can run in parallel and are concurrent ?

DEPLOYMENT view : Allocation Structures. Relation with external elements What processor does each software element execute on? In what files is each element stored during development, testing, and

system building?

Page 8: Sa 008 architecture_views

UML 2.0 for Architecture

8 Vakgroep Informatietechnologie – Onderzoeksgroep IBCN

Page 9: Sa 008 architecture_views

Vakgroep Informatietechnologie – Onderzoeksgroep IBCN p. 9

STATIC Views & Modules Structures

Module

Decomposition UsesClass

Layered

Modules are units of implementation. with functional responsibility is a sub module of and uses - relations generalisation -> re-use & incremental development associated products: test plan, interface specification,

code …etc.

Page 10: Sa 008 architecture_views

Module Structures in UML

Represented stereotyped packages, classes and interfaces

Vakgroep Informatietechnologie – Onderzoeksgroep IBCN p. 10

Page 11: Sa 008 architecture_views

UML Interfaces Representations

Provided interfaces

Required interfaces

Example: HTTP Server

11 Vakgroep Informatietechnologie – Onderzoeksgroep IBCN

Page 12: Sa 008 architecture_views

Component Diagrams A component is a modular, autonomous unit with well

defined interfaces. They are particularly well suited for initial architectural

modeling.

12

Static View

Dynamic View

Vakgroep Informatietechnologie – Onderzoeksgroep IBCN

Page 13: Sa 008 architecture_views

p. 13

DYNAMIC Views & Component-Connector

Component – Connector Structures

Client -

ServerConcurrency

Shared data

Components are runtime units computational units parallelism, identify resource contention

Connectors are interaction mechanism among components

communication & synchronisation mechanism interaction, data flow (persistence).

Communication

Processes

Vakgroep Informatietechnologie – Onderzoeksgroep IBCN

Page 14: Sa 008 architecture_views

Dynamic Views in UML

14 Vakgroep Informatietechnologie – Onderzoeksgroep IBCN

Page 15: Sa 008 architecture_views

Interaction diagrams

Interaction diagrams show the communication behavior between parts of the systemFour types of Interaction diagrams

Sequence diagram Emphasis on the sequence of communications between parts

Communication diagram Emphasis on structure and the communication paths between

parts

Timing diagram Emphasis on change in state over time

Interaction overview diagram Emphasis on flow of control between interactions

15 Vakgroep Informatietechnologie – Onderzoeksgroep IBCN

Page 16: Sa 008 architecture_views

Sequence diagram

16 Vakgroep Informatietechnologie – Onderzoeksgroep IBCN

Page 17: Sa 008 architecture_views

Communication Diagram

17 Vakgroep Informatietechnologie – Onderzoeksgroep IBCN

Page 18: Sa 008 architecture_views

Vakgroep Informatietechnologie – Onderzoeksgroep IBCN p. 18

Example: Static & Dynamic view

Page 19: Sa 008 architecture_views

Vakgroep Informatietechnologie – Onderzoeksgroep IBCN p. 19

DEPLOYMENT Views & Allocation structures

Allocation

Work

AssignmentDeployment

Implementation

Allocation structures show relations in the external environment:

assignment to processors and communication resources

mapping to file structures and build systems who does the work

Page 20: Sa 008 architecture_views

Vakgroep Informatietechnologie – Onderzoeksgroep IBCN p. 20

UML Deployment Diagrams

Node “computational unit”(processor, computer, sensor, ...)

aNode

Page 21: Sa 008 architecture_views

Vakgroep Informatietechnologie – Onderzoeksgroep IBCN p. 21

Example WWW Client Server

Page 22: Sa 008 architecture_views

Vakgroep Informatietechnologie – Onderzoeksgroep IBCN p. 22

HTTP Client Module

UI manager : Responsible for the look and feel of the UI (e.g., web browser)

Presentation manager Delegates document types to viewers

external: QuickTime movies, MP3 audio, etc. internal: HTML, GIFs to UI manager

Scenario: UI manager captures user’s requests for URL and passes to

Access manager Access manager determines if URL has been cached; if not, it

initiates retrieval through Protocol and Stream managers Response stream sent to presentation manager for

appropriate display

Page 23: Sa 008 architecture_views

Vakgroep Informatietechnologie – Onderzoeksgroep IBCN p. 23

HTTP Server Module

Hypertext Transfer Protocol (HTTP) server : Receives URL request and passes that the Path resolver, which

determines the file location for the document (assuming local) Checks the access list to see if access is permitted (may initiate

password authentication session) and then gets the document from the file system and writes it to the output stream

Common Gateway Interface (CGI) Special document type that allows customized access to other

data or programs Also writes to output stream

HTML stream is sent to the client by the HTTP server

Page 24: Sa 008 architecture_views

Vakgroep Informatietechnologie – Onderzoeksgroep IBCN p. 24

Common Gateway Interface (CGI)

HTTP server : transparent access to the file system by: Handling access directly for known types Passing unknown types to a “proxy” server known as Common

Gateway Interface (CGI)

CGI Most information returned by the server is “static” CGI provides for the dynamic generation of responses e.g.

“looking something up in a database” Virtual documents or dynamic documents CGI Scripts: C, C++, Perl, Visual Basic, AppleScript, PHP,