Sunday, July 23, 2017

What is a Component? | An Object-Oriented View | The Traditional View | A Process-Related View

What is a Component?

  • A component is a modular building block for computer software. 
  • As per OMG Unified Modeling Language Specification defines 
  • A component is a modular, deployable, and replaceable part of a system that encapsulates implementation and exposes a set of interfaces. 
  • The true meaning of the term component will differ depending on the point of view of the software engineer who uses it. Based on that, 
Three different views of Components
  • Three important views of what a component is and how it is used as design modeling proceeds. 
    • (1) An Object-Oriented View
    • (2) The Traditional View 
    • (3) A Process-Related View

(1) An Object-Oriented View

  • In the context of object-oriented software engineering, a component contains a set of collaborating classes. 
  • Each class within a component has been fully elaborated to include all attributes and operations that are relevant to its implementation. 
  • As part of the design elaboration, all interfaces that enable the classes to communicate and collaborate with other design classes must also be defined.
  • To accomplish this, you begin with the requirements model and elaborate analysis classes (for components that relate to the problem domain)
An Object-Oriented View

Explanation of Figure : 
  • To illustrate this process of design elaboration, consider software to be built for a sophisticated print shop. 
  • The overall objective of the software is to collect the customer’s requirements at the front counter, cost a print job, and then pass the job on to an automated production facility. 
  • During requirements engineering, an analysis class called PrintJob was derived. The attributes and operations defined during analysis are noted at the top of Figure. 
  • During architectural design, PrintJob is defined as a component within the software architecture and is represented using the shorthand UML notation shown in the middle right of the figure.
  • Note that PrintJob has two interfaces, computeJob, which provides job costing capability, and initiateJob, which passes the job along to the production facility. These are represented using the “lollipop” symbols shown to the left of the component box. 
  • Component-level design begins at this point. The details of the component PrintJob must be elaborated to provide sufficient information to guide implementation. The original analysis class is elaborated to flesh out all attributes and operations required to implement the class as the component PrintJob.

(2) The Traditional View

  • In the context of traditional software engineering, a component is a functional element of a program that incorporates 
    • Processing logic
    • The internal data structures that are required to implement the processing logic, 
    • An interface that enables the component to be invoked and data to be passed to it. 
  • A traditional component, also called a module, resides within the software architecture and serves one of three important roles: 
    • (1) A control component that coordinates the invocation of all other problem domain components, 
    • (2) A problem domain component that implements a complete or partial function that is required by the customer,
    • (3) An infrastructure component that is responsible for functions that support the processing required in the problem domain.
The Traditional View
The Traditional View

(3) A Process-Related View

  • Assume that the component is being designed from scratch or used an existing components for new development. 
  • That is, you have to create a new component based on specifications derived from the requirements model. 
  • There is, of course, another approach. 
  • The software engineering community has emphasized the need to build systems that make use of existing software components or design patterns. 
  • In essence, a catalog of proven design or code-level components is made available to you as design work proceeds. 
  • As the software architecture is developed, you choose components or design patterns from the catalog and use them to populate the architecture. 
  • Because these components have been created with reusability in mind, a complete description of their interface, the function(s) they perform, and the communication and collaboration they require are all available to you.

Saturday, July 22, 2017

Architectural Mapping Using Data Flow | Transform Mapping

Architectural Mapping Using Data Flow

  • A mapping technique, called structured design, is often characterized as a data flow-oriented design method because it provides a convenient transition from a data flow diagram to software architecture. 
  • The transition from information flow to program structure is accomplished as part of a six step process: 
    • (1) The type of information flow is established, 
    • (2) Flow boundaries are indicated,
    • (3) The DFD is mapped into the program structure, 
    • (4) Control hierarchy is defined, 
    • (5) The resultant structure is refined using design measures. 
    • (6) The architectural description is refined and elaborated.
  • Example of data flow mapping, a step-by-step “transform” mapping for a small part of the SafeHome security function. 
  • In order to perform the mapping,
  • The type of information flow must be determined. It is called transform flow and exhibits a linear quality. 
  • Data flows into the system along an incoming flow path where it is transformed from an external world representation into internalized form. Once it has been internalized, it is processed at a transform center. 
  • Finally, it flows out of the system along an outgoing flow path that transforms the data into external world form.

 Transform Mapping

  • Transform mapping is a set of design steps that allows a DFD with transform flow characteristics to be mapped into a specific architectural style. 
  • To illustrate this approach, we again consider the SafeHome security function. 
  • To map these data flow diagrams into a software architecture, you would initiate the following design steps: 
    • Step 1. Review the fundamental system model.
    • Step 2. Review and refine data flow diagrams for the software. 
    • Step 3. Determine whether the DFD has transform or transaction flow characteristics. 
    • Step 4. Isolate the transform center by specifying incoming and outgoing flow boundaries. 
    • Step 5. Perform “first-level factoring.”
    • Step 6. Perform “second-level factoring.” 
  • Step 7. Refine the first-iteration architecture using design heuristic for improved software quality. 

Tuesday, July 18, 2017

Assessing Alternative Architectural Design | An Architecture Trade-Off Analysis Method | Architectural Complexity | Architectural Description Language | An Architectural Design Method | Deriving Program Architecture

Assessing Alternative Architectural Design

  • Design results in a number of architectural alternatives that are each assessed to determine which is the most appropriate for the problem to be solved. 
  • Two different approaches for the assessment of alternative architectural designs. 
    • (1) The first method uses an iterative method to assess design trade-offs.
    • (2)The second approach applies a pseudo-quantitative technique for assessing design quality.

An Architecture Trade-Off Analysis Method

  • The Software Engineering Institute (SEI) has developed an architecture trade-off analysis method (ATAM) that establishes an iterative evaluation process for software architectures. 
  • The design analysis activities that follow are performed iteratively. 
  • 1. Collect scenarios : A set of use cases is developed to represent the system from the user’s point of view. 
  • 2. Elicit (Bring out) requirements, constraints, and environment description. This information is determined as part of requirements engineering and is used to be certain that all stakeholder concerns have been addressed. 
  • 3. Describe the architectural styles/patterns that have been chosen to address the scenarios and requirements. 
  • The architectural style(s) should be described using one of the following architectural views… 
    • Module view for analysis of work assignments with components and the degree to which information hiding has been achieved. 
    • Process view for analysis of system performance. 
    • Data flow view for analysis of the degree to which the architecture meets functional requirements.
  • 4. Evaluate quality attributes : Quality attributes for architectural design assessment include reliability, performance, security, maintainability, flexibility, testability, portability, reusability, and interoperability. 
  • 5.Identify the sensitivity of quality attributes to various architectural attributes for a specific architectural style. This can be accomplished by making small changes in the architecture and determining how sensitive a quality attribute, say performance, is to the change. Any attributes that are significantly affected by variationin the architecture are termed sensitivity points.. 
  • 6. Critique (Assess) candidate architectures (developed in step 3) using the sensitivity analysis conducted in step 5. 
  • The Software Engineering Institute (SEI) describes this approach in the following manner 
    • Once the architectural sensitivity points have been determined, finding trade-off points is simply the identification of architectural elements to which multiple attributes are sensitive. For example, the performance of a client-server architecture might be highly sensitive to the number of servers (performance increases, within some range, by increasing the number of servers). . . . The number of servers, then, is a trade-off point with respect to this architecture.

Architectural Complexity

  • A useful technique for assessing the overall complexity of a proposed architecture is to consider dependencies between components within the architecture. 
  • These dependencies are driven by information/control flow within the system. Zhao suggests three types of dependencies:
    • Sharing dependencies represent dependence relationships among consumers who use the same resource or producers who produce for the same consumers. 
    • For example, for two components u and v, if u and v refer to the same global data, then there exists a shared dependence relationship between u and v. 
    • Flow dependencies represent dependence relationships between producers and consumers of resources 
    • Constrained dependencies represent constraints on the relative flow of control among a set of activities. For example, for two components u and v, u and v cannot execute at the same time (mutual exclusion), then there exists a constrained dependence relationship between u and v.

Architectural Description Language

  • Introduction:
  • The architect of a house has a set of standardized tools and notation that allow the design to be represented in an unambiguous, understandable fashion. 
  • The software architect can draw on Unified Modeling Language (UML) notation, other diagrammatic forms, and a few related tools, there is a need for a more formal approach to the specification of an architectural design. 
  • Architectural description language (ADL) provides a semantics and syntax for describing a software architecture. 
  • Hofmann and his colleagues suggest that 
    • An ADL should provide the designer with the ability to decompose architectural components, 
    • Compose individual components into larger architectural blocks, 
    • Represent interfaces (connection mechanisms) between components. 
  • Once descriptive, language based techniques for architectural design have been established, it is more likely that effective assessment methods for architectures will be established as the design evolves.

An Architectural Design Method

An Architectural Design Method

Deriving Program Architecture

Deriving Program Architecture

Wednesday, July 12, 2017

Architectural Design | Representing the System in Context | Defining Archetypes | Refining the Architecture into Components | Describing Instantiations of the System

Architectural Design

  • Introduction : 
  • As architectural design begins, the software to be developed must be put into context— 
  • That is, the design should define the external entities (other systems, devices, people) that the software interacts with and the nature of the interaction. 
  • This information can generally be acquired from the requirements model and all other information gathered during requirements engineering. 
  • Once context is modeled and all external software interfaces have been described, you can identify a set of architectural archetypes.
  • An archetype is an abstraction (similar to a class) that represents one element of system behavior. 
  • The set of archetypes provides a collection of abstractions that must be modeled architecturally if the system is to be constructed, but the archetypes themselves do not provide enough implementation detail. 
  • Therefore, the designer specifies the structure of the system by defining and refining software components that implement each archetype. 
  • This process continues iteratively until a complete architectural structure has been derived..

Representing the System in Context

  • At the architectural design level, a software architect uses an architectural context diagram (ACD) to model the manner in which software interacts with entities external to its boundaries. 
  • The generic structure of the architectural context diagram is illustrated in Figure.

Representing the System in Context

  • In figure, systems that interoperate with the target system (the system for which an architectural design is to be developed) are represented as
    • Super ordinate systems : those systems that use the target system as part of some higher-level processing scheme. 
    • Subordinate systems—those systems that are used by the target system and provide data or processing that are necessary to complete target system functionality. 
    • Peer-level systems—those systems that interact on a peer-to- peer basis (i.e., information is either produced or consumed by the peers and the target system. 
    • Actors—entities (people, devices) that interact with the target system by producing or consuming information. 
  • Each of these external entities communicates with the target system through an interface (the small shaded rectangles).

Defining Archetypes

  • An archetype is a class or pattern that represents a core abstraction that is critical to the design of an architecture for the target system. 
  • In general, a relatively small set of archetypes is required to design even relatively complex systems. 
  • Archetypes are the abstract building blocks of an architectural design.
  • In many cases, archetypes can be derived by examining the analysis classes defined as part of the requirements model. 
  • An archetype is a generic, idealized model of a person, object, or concept from which similar instances are derived, copied, patterned, or emulated. 
  • For example, an archetype for a car: wheels, doors, seats, engine In software engineering
  • As per in previous figure : The SafeHome home security function, you might define the following archetypes : 
    • Node : Represents a cohesive collection of input and output elements of the home security function.
    • For example a node might be included of (1) various sensors and (2) a variety of alarm (output) indicators. 
    • Detector : An abstraction that covers all sensing equipment that feeds information into the target system. 
    • Indicator. An abstraction that represents all mechanisms (e.g., alarm siren, flashing lights, bell) for indicating that an alarm condition is occurring. 
    • Controller. An abstraction that describes the mechanism that allows the arming (Supporting) or disarming of a node. If controllers reside on a network, they have the ability to communicate with one another.

 Refining the Architecture into Components

  • As the software architecture is refined into components. 
  • Analysis classes represent entities within the application (business) domain that must be addressed within the software architecture. 
  • In some cases (e.g., a graphical user interface), a complete subsystem architecture with many components must be designed. 
  • For Example : The SafeHome home security function example, you might define the set of top-level components that address the following functionality: 
  • External communication management — coordinates communication of the security function with external entities such as other Internet-based systems and external alarm notification. 
  • Control panel processing— manages all control panel functionality. 
  • Detector management — coordinates access to all detectors attached to the system. 
  • Alarm processing — verifies and acts on all alarm conditions
  • The overall architectural structure (represented as a UML component diagram) is in the following Figure.
Refining the Architecture into Components

Describing Instantiations of the System

  • The architectural design that has been modeled to this point is still relatively high level. 
  • The context of the system has been represented 
  • Archetypes that indicate the important abstractions within the problem domain have been defined, 
  • The overall structure of the system is apparent, and the major software components have been identified. 
  • However, further refinement is still necessary. 
  • To accomplish this, an actual instantiation of the architecture is developed.It means, again it simplify by more details. 
  • The figure demonstrates this concept.
Describing Instantiations of the System

Architectural Pattern

Architectural Pattern

  • As the requirements model is developed, you’ll notice that the software must addressa number of broadproblems that span the entire application. 
  • For example, the requirements model for virtually every e-commerce application is faced with the following problem:
    • How do we offer a broad array of goods to a broad array of customers? 
    • Allow those customers to purchase our goods online?
  • The requirements model also defines a context in which this question must be answered. 
  • For example, an e-commerce business that sells golf equipment to consumers will operate in a different context than an e-commerce business that sells high-priced industrialequipment to medium and large corporations.
  • In addition, a set of limitations and constraints may affect the way in which you addressthe problem to be solved. 
  • Architectural patterns address an application-specific problem within a specific context and under a set of limitations and constraints. 
  • The pattern proposes an architectural solution that can serve as the basis for architectural design…

Tuesday, July 11, 2017

Architectural Styles | Taxonomy of Architectural Styles | Data-Centered Architecture | Data Flow architectures | Call and return architectures | Object-oriented architectures | Layered architectures

Architectural Styles

  • Introduction : 
  • For example (For understanding purpose)
  • When a builder uses the phrase “center hall colonial” to describe a house, most people familiar with houses in a general image of what the house will look like and what the floor plan is likely to be. 
  • The builder has used an architectural style as a descriptive mechanism to differentiate the house from other styles (e.g., A-frame, raised ranch, Cape Cod). 
  • The architectural style is also a template for construction. 
  • Further details of the house must be defined, its final dimensions must be specified, customized features may be added, building materials are to be determined, but the style—a “center hall colonial”—guides the builder in his work. 
  • software architecture represents a structure in which some collection of entities (often called components) is connected by a set of defined relationships (often called connectors). 
  • Both components and connectors are associated with a set of properties that allow the designer to differentiate the types of components and connectors that can be used.
  • Introduction: 
  • The software that is built for computer-based systems also exhibits one of many architectural styles.
  • Each style describes a system category that encompasses 
    • (1) A set of components (e.g., a database, computational modules) that perform a function required by a system; 
    • (2) A set of connectors that enable “communication, coordination and cooperation” among components;
    • (3) Constraints that define how components can be integrated to form the system;
    • (4) Semantic models that enable a designer to understand the overall properties of a system by analyzing the known properties of its constituent parts.

Taxonomy of Architectural Styles

  • Introduction:
  • Millions of computer-based systems have been created over the past 60 years, the vast majority can be categorized into one of a relatively small number of architectural styles 
  • The following are the Taxonomy (Classification) of Architectural Style
    • (1) Data-centered architectures 
    • (2) Data flow architectures 
    • (3) Call and return architectures 
    • (4) Object-oriented architectures
    • (5) Layered architectures

Data-Centered Architecture

Data-Centered Architecture

  • Introduction:
  • A data store (e.g., a file or database) resides at the center of this architecture and is accessed frequently by other components that 
    • update, add, delete, or otherwise modify data within the store. 
  • Figure in slide, illustrates a typical data-centered style. Client software accesses a central repository (Storage area).
  • Data-centered architectures promote inerrability. That is, existing components can be changed and new client components added to the architecture without concern about other clients 
  • (because the client components operate independently). 
  • In addition, data can be passed among clients using the black-board mechanism (i.e., the blackboard component serves to coordinate the transfer of information between clients). 
  • Client components independently execute processes.

Data Flow architectures

  • This architecture is applied when input data are to be transformed through a series of computational or manipulative components into output data. 
  • A pipe-and-filter pattern (in Figure) has a set of components, called filters, connected by pipes that transmit data from one component to the next.
  • Each filter works independently of those components upstream and downstream, is designed to expect data input of a certain form, and produces data output (to the next filter) of a specified form. 
  • However, the filter does not require knowledge of the workings of its neighboring filters. 
  • If the data flow degenerates into a single line of transforms, it is termed batch sequential. This structure accepts a batch of data and then applies a series of sequential components (filters) to transform it
batch sequential

pipes filters

An example of the pipe and filter architecture

An example of the pipe and filter architecture

Call and return architectures

  • This architectural style enables you to achieve a program structure that is relatively easy to modify and scale.
  • A number of substyles exist within this category…
  • Main program/subprogram architectures. This classic program structure decomposes function into a control hierarchy where a “main” program” invokes a number of program components that in turn may invoke still other components. an architecture of this type.
  • Remote procedure call architectures. The components of a main program/subprogram architecture are distributed across multiple computers on a network.
Main program/subprogram architectures

Object-oriented architectures

  • The components of a system encapsulate data and the operations that must be applied to manipulate the data.
  • Communication and coordination between components are accomplished via message passing…

Layered architectures

Layered architectures
  • The basic structure of a layered architecture is illustrated in Figure.
  • A number of different layers are defined, each accomplishing operations that progressively become closer to the machine instruction set.
  • At the outer layer, components service user interface operations.
  • At the inner layer, components perform operating system interfacing.
  • Intermediate layers provide utility services and application software functions…

Monday, July 10, 2017

Architectural design | What is Architecture? | Difference between Architectural & Design

Introduction of Architectural design

  • Architectural design represents
    • The structure of data
    • Program components ,that are required to build a computerbased system.
  • Architectural design considers the architectural style that the system will take, 
    • The structure and properties of the components that constitute the system, 
    • The interrelationships that occur among all architectural components of a system.

What is Architecture?

  • Bass, Clements, and Kazman define this term in the following way:
  • The software architecture of a program or computing system is the structure or structures of the system, which comprise (include) software components, the externally visible properties of those components, and the relationships among them. 
  • For example : It is something like building a home and prepare a model of it. Finally, it is an art. 
  • The architecture is not the operational software. Rather, it is a representation that enables you to 
    • (1) Analyze the effectiveness of the design in meeting its stated requirements, 
    • (2) Consider architectural alternatives at a stage when making design changes is still relatively easy, 
    • (3) Reduce the risks associated with the construction of the software.
  • The definition emphasizes the role of “software components” in any architectural representation. 
  • In the context of architectural design, a software component can be something as simple as a 
    • Program module or an object-oriented class, 
    • Database
    • Middleware
  • The properties of components are those characteristics that are necessary for an understanding of how the components interact with other components. 
  • At the architectural level, internal properties (e.g., details of an algorithm) are not specified. 
  • The relationships between components can be as simple as a procedure call from one module to another or as complex as a database access protocol.

Difference between Architectural & Design

  • Introduction
  • For example (For understanding purpose)
  • When a builder uses the phrase “center hall colonial” to describe a house, most people familiar with houses in a general image of what the house will look like and what the floor plan is likely to be. 
  • The builder has used an architectural style as a descriptive mechanism to differentiate the house from other styles (e.g., A-frame, raised ranch, Cape Cod). 
  • The architectural style is also a template for construction. 
  • Further details of the house must be defined, its final dimensions must be specified, customized features may be added, building materials are to be determined, but the style—a “center hall colonial”—guides the builder in his work. 
  • software architecture represents a structure in which some collection of entities (often called components) is connected by a set of defined relationships (often called connectors). 
  • Both components and connectors are associated with a set of properties that allow the designer to differentiate the types of components and connectors that can be used.