Presentation is loading. Please wait.

Presentation is loading. Please wait.

Software Architecture

Similar presentations


Presentation on theme: "Software Architecture"— Presentation transcript:

1 Software Architecture

2 Software Architecture
Describes overall system organization and structure in terms of its major constituents and their interactions Promotes independence of modules Decoupled modules can be developed and tested independently Enhances ability to change Poorly architected software is difficult to change Reduces cost/time to implement Helps formalize, organize, prioritize decisions

3 Architecture Defined If architecture is strategic design, then the rest of the design is the tactical design. Architecture establishes the context for further design and implementation architecture design implementation CODE Architecture focuses on significant design decisions that have a lasting impact on the performance, reliability, cost, and resilience of the system

4 Architecture Defined IEEE Software architecture encompasses
Emphasize that the rationale for the architectural decisions is very important. IEEE Software architecture is the fundamental organization of a system, including its components, their relationships to each other and the environment, and the principles governing its design and evolution Software architecture encompasses Selection of the structural elements and interfaces by which a system is composed Decomposition of subsystems into constituent structural and behavioral elements Behavior as specified in collaborations among those elements Architectural style that guides this organization

5 Example 1

6 Example 2

7 Architectures Follow Patterns
Common solution to a common problem Codifies specific knowledge collected from experience in a domain

8 Examples of Architectural Patterns
Repository Data-flow Centralized Control Client-Server Event Driven Layered Systems Object Oriented Domain Specific

9 Repository Sub-systems exchange data
A shared central database or repository can be accessed by all sub-systems Each sub-system maintains its own database elements and passes data to those for use by other sub-systems When large amounts of data are to be shared, the repository model of sharing is most commonly used

10 Repository Advantages
Efficiency: no need for inter-subsystem communication for data transfer Transparency: sub-systems need not be concerned with how data is produced. Centralized management Standard: sharing model is published as the repository schema Disadvantages Sub-systems must agree on a repository data model (compromise) Data evolution is difficult/expensive Difficult to distribute efficiently

11 Data-flow Functional transformations process their inputs to produce outputs May be referred to as pipe and filter model (UNIX shell) When transformations are sequential, this is a batch sequential model which is extensively used in data processing systems Not directly suitable for interactive systems

12 Centralized Control A control sub-system takes responsibility for managing the execution of other sub-systems Call-return model Top-down subroutine model where control starts at the top of a subroutine hierarchy and moves downwards. Applicable to sequential systems Manager model Applicable to concurrent systems. One component controls the stopping, starting and coordination of other system processes. Can be implemented in sequential systems as a case statement

13 Model-View-Controller
Variant of centralized control architecture; Controller processes user commands which manipulate data in the model, and calls on various views. Controller (interact with user, perform commands View (display model for user) Model (store data, e.g. text)

14 Client-server Distributed system model that shows how data and processing is distributed across a range of components Set of stand-alone servers that provide specific services such as printing, data management, etc. Set of clients that call on these services Network that allows clients to access servers

15 Client-server Advantages Distribution of data is straightforward
Makes effective use of networked systems. May require cheaper hardware Easy to add new servers or upgrade existing servers Disadvantages No shared data model so sub-systems use different data organization - data interchange may be inefficient Redundant management in each server No central register of names and services - it may be hard to find out what servers and services are available

16 Event-driven Driven by externally generated events where the timing of the event is outside of the control of the sub-systems which process the event Two main event-driven models Broadcast models. An event is broadcast to all sub-systems. Any sub-system which can handle the event may do so Interrupt-driven models. Used in real-time systems where interrupts are detected by an interrupt handler and passed to some other component for processing

17 Layered Systems Model the interfacing of sub-systems
Organises the system into a set of layers (or abstract machines) each of which provide a set of services Supports incremental development of sub-systems in different layers. When a layer interface changes, only the adjacent layer is affected However, often difficult to structure systems in this way V e r s i o n m a n a g e m e n t O b j e c t m a n a g e m e n t D a t a b a s e s y s t e m O p e r a t i n g s y s t e m

18 Object Oriented Structure the system into a set of loosely coupled objects with well-defined interfaces Object-oriented decomposition is concerned with identifying object classes, their attributes and operations When implemented, objects are created from these classes and some control model used to coordinate object operations

19 Domain-Specific: e.g., Compiler
Compiler model is a well-known example although other models exist in more specialized application domains Lexical analyser Symbol table Syntax analyser Syntax tree Semantic analyser Code generator Generic compiler model may be organized according to different architectural models

20 Exercises What architectural style would you use, and why, for the following: Software controlling an elevator Software automating a fantasy baseball league Software automating a library’s book and patron information and tasks such as check-in/check-out A company’s payroll software

21 Examples of Architectural Patterns
Repository Data-flow Centralized Control Client-Server Event Driven Layered Systems Object Oriented Domain Specific

22 Example 3


Download ppt "Software Architecture"

Similar presentations


Ads by Google