SDA Final Ratta
SDA Final Ratta
2. Perspectives on Design:
Design thinking can be categorized into three perspectives:
o Design as Styling: Focuses on the aesthetic and usability aspects (e.g., user interfaces,
fashion, product appearance).
o Creativity and Envisioning: Requires imagining how something might work and devising
methods to achieve it.
o Balance: A good design must balance functionality, efficiency, user appeal, and
adaptability.
o Interdependence: The way a design plan is created influences the design process, and
vice versa.
o Challenges: Software design involves tackling ill-structured problems (ISPs) with no clear
true/false answers, demanding creativity and foresight.
o Technical Debt: Decisions in design affect future software evolution, requiring careful
thought to avoid unsustainable practices.
5. Goal of Design Thinking:
o For software, this involves ensuring designs are practical, adaptable, and user-friendly
while avoiding inefficiencies and "software lemons."
• Characteristics of ISPs
o There is no definitive formulation of an ISP
o ISPs have no stopping rule.
o Solutions to ISPs are not true or false, but good or bad.
o There is no immediate and no ultimate test of a solution to an ISP.
o Every ISP is essentially unique.
Design Activities
1. Postulate a Solution: Predict and organize how a solution may address the need.
2. Build a Model: Create a design model as a representation of the solution.
3. Evaluate the Model: Assess the model against requirements and refine iteratively.
4. Elaborate for Realization: Develop the model into a detailed plan for implementation.
Design Process Characteristics
• Iterative: Requires cycles of refinement and backtracking as issues arise or objectives shift.
• Uncertain: Early designs may fail or be suboptimal, revealing new challenges or opportunities.
• Complex: Designers often manipulate physical and abstract elements simultaneously, such as
processes in software.
Managing design processes
1. Human Cognitive Limitations
• Designers face challenges in handling multiple complex design elements due to these cognitive
limits, necessitating tools and strategies to manage complexity.
2. Abstraction as a Core Concept
• Abstraction simplifies design by focusing on relevant details while omitting unnecessary
specifics.
• It reduces cognitive load, enabling designers to conceptualize systems more effectively.
3. Designing Systems
• System design involves creating models that address specific needs from requirements.
• Early design decisions (e.g., architectural style) often involve trade-offs based on criteria like
speed, functionality, and future adaptability.
4. Decision-Making in Design
• Designers balance competing priorities, such as functional requirements and technical debt.
• Fitness for purpose is the ultimate criterion, focusing on the system’s ability to perform the
required tasks reliably at a reasonable cost.
5. Design Models and Tools
• Abstract models, including diagrams and text, help manage cognitive processes and evaluate
design scenarios.
• Walk-throughs and scenario evaluations assist in identifying issues and refining solutions.
6. Fitness for Purpose and Performance
• Systems should meet defined expectations of functionality and reliability.
• Context-specific considerations, like safety-critical systems, demand precise criteria, whereas
others (e.g., image recognition) may accept certain limitations.
• Designers must anticipate acceptable shortfalls and ensure they align with user expectations.
Characteristics of Good Design:
• Abstraction: Focus on core issues, discarding irrelevant details.
• Fitness for Purpose: The design must meet requirements effectively.
• Design Models: The outcome of the design process must be formally recorded and shared.
• Team Collaboration: Developers need a shared understanding of goals and models.
• Adaptability: Software designers often work across various domains, requiring diverse skills and
flexibility.
Software Elements
• Functions & Dependencies: Elements have well-defined functions and connect via connectors
forming a dependency graph.
• Transformation & Attributes: Refined through steps based on attributes and project
requirements.
o Multiplicity:
Implementation Guidelines:
4. Heavy Computation: Deploy on processor clusters for load balancing and minimal
communication traffic.
6. Complex Elements:
Software Connectors
• Refinement: Based on deployment environments (e.g., local method calls, message queues, or
remote invocations).
• Classification Attributes:
1. Synchronization Mode:
2. Initiator:
3. Information Carrier:
4. Implementation Type:
5. Active Time:
6. Span:
7. Fan-out:
8. Environment:
Garlan and Shaw (1996) list the following requirements for an ADL:
• Abstraction: “It should be possible to describe the components and their interactions in a way
that describes their abstract roles in a system.” It should not be necessary to consider
implementation issues while specifying the architecture.
• Reuse: Reusability should be built-in at the component and connection level. The derivation of
architecture patterns should also be supported to facilitate the reuse of architecture
descriptions.
• Analysis: The use of an ADL should facilitate the analysis of an architecture design. Analysis
might include consideration of throughput, deadlock, input/output behavior, and scheduling.
1. Principle of Decoupling:
• Benefits:
o Reduced interdependency.
o Simplified implementation.
2. Ensuring Cohesion:
• Benefits:
3. Open-Closed Principle:
• Guidelines:
o Keep attributes private to avoid ripple effects and ensure thread safety.
o Minimize the use of global and static variables to prevent misuse and crashes.
Distributed Architecture
1. Client-Server
Advantages:
• Separation of responsibilities such as user interface presentation and business logic processing
• Reusability of server components
Disadvantages:
• Lack of heterogeneous infrastructure to deal with the requirement changes
• Security complications
• Server availability and reliability
• Testability and scalability
• Fat clients with presentation and business logic together
2. Broker architecture style
Definition: The Broker Architecture is a middleware pattern facilitating communication between clients
and servers through a broker component, ensuring decoupled interaction via remote service invocations.
Key Components:
1. Broker:
o Manages communication by forwarding requests, locating servers, and returning results
or exceptions.
o Stores server registration information and provides APIs for client-server interactions.
2. Stub (Client Proxy):
o Mediates between the client and broker, offering transparency.
o Handles protocol-level communication, marshaling arguments, and unmarshaling
results.
3. Skeleton (Server Proxy):
o Mediates between the server and broker, managing system-specific networking.
o Unpacks requests, invokes services, and marshals results for the client.
4. Bridges (Optional):
o Enable interoperability between different brokers (e.g., DCOM, CORBA).
o Translate requests and parameters between formats.
5. Network:
o Connects components using protocols like TCP/IP, SOAP, or HTTP for data transfer.
Workflow:
• Client requests are intercepted by the client-proxy, processed by the broker, and forwarded to
the server-proxy.
• The server-proxy invokes the appropriate service and returns results to the broker, which
forwards them to the client.
Advantages:
• Transparency in server implementation and location.
• Flexibility for runtime changes (e.g., adding/removing servers).
• Simplified client access and server portability.
• Enhanced reusability and interoperability via bridges.
Disadvantages:
• Overhead from proxies reduces efficiency.
• Low fault-tolerance.
• Complex testing due to multiple proxies.
Applications:
• Commonly implemented in systems like CORBA, Java RMI, and .NET Remote, enabling seamless
distributed service access with location transparency and minimal client effort.
Message broker architecture
Advantages:
• Reusability and maintainability: Loose coupling between the client and server component leads to easy
maintenance and extension on both sides.
• Flexibility: Invocation-oriented or document-oriented messaging; message heading and body can be
altered for specific purposes.
Disadvantages:
• Overhead, indirection complexity, and difficulty in debugging and testing due to the new protocol stack
added
3. Service-Oriented Architecture (SOA)
Definition:
Service-Oriented Architecture (SOA) is a design paradigm where business processes are implemented as
modular, reusable, and independent services with well-defined interfaces. These services communicate
using universal protocols like SOAP, XML, and HTTP, ensuring loose coupling and platform independence.
SOA enables the reuse of services across applications and simplifies the integration of legacy systems.
How It Works:
• Clients access services via a service directory.
• Services interact through message-oriented protocols.
• Business workflows are orchestrated using languages like BPEL, enabling seamless integration of
services.
Key Features:
• Loose Coupling: Services are stateless and independent, allowing for seamless updates without
impacting clients.
• Service Composition: Complex applications can be built by aggregating and reusing atomic
services.
• Interoperability: Services communicate regardless of platform, technology, or language.
Advantages of SOA:
1. Loosely-Coupled Connections:
o Independent service components ensure easier evolution and updates.
o Stateless design enables scalability and flexibility.
2. Interoperability:
o Allows seamless communication across platforms, technologies, and vendors.
o Universal message formats like XML enhance compatibility.
3. Reusability:
o Services can be reused across applications, reducing development time and costs.
o Promotes efficiency and consistency in business applications.
4. Scalability:
o Easily scales to accommodate growing business demands.
o Coarse-grained and asynchronous design improves performance under load.
SOA in Practice:
• Web Services: Implemented using protocols like SOAP and WSDL for communication and
description.
• BPEL: Orchestrates workflows among services, defining their sequence and interactions.
• Grid Service Computing: Leverages SOA to integrate distributed computational and data
resources for efficient resource management.
Component-Based Software Architecture
Applicable domains of component-based architecture:
• Applications where the interface contracts between subsystems are clear
• Applications that require loose coupling between the components and where many reusable
components are available
• Suitable for the class library system organization (.NET class library and Java API are built in component
architecture)
Benefits:
• Reusability of components.
• System maintenance and evolution; easy to change and update the implementation without affecting
the rest of the system.
• Independency and flexible connectivity of components.
• Independent development of components by different groups in parallel.
• Productivity for the current and future software development.
• Many OO design tools can also be used for component-based software development.
Limitations:
• It can be difficult to find suitable available components to reuse.
• Adaptation of components is an issue.
• Few component-oriented dedicated design tools are available
CLO-3 (Gorton Chapter 4)
1. The transport layer provides basic pipes for sending requests and moving data, ensuring
straightforward data exchange in distributed architectures.
2. Application servers, built on transport services, offer transaction, security, and directory services
while supporting a programming model for creating multithreaded, server-based applications.
3. Message brokers utilize a basic transport service and/or application servers, incorporating a
specialized message processing engine that offers fast message transformation and high-level
programming features for routing, manipulating, and exchanging messages between application
components.
4. Business process orchestrators (BPOs) augment message broker features to support workflow-
style applications. In such applications, business processes may take many hours or days to
complete due to the need for people to perform certain tasks. BPOs provide the tools to
describe such business processes, execute them and manage the intermediate states while each
step in the process is executed.
Message-Oriented Middleware
1. Message delivery
Quality of service:
Persistent: The MOM layer guarantees to deliver messages despite system and network failures.
Undelivered messages are logged to disk as well as being kept in memory and so can be recovered
and subsequently delivered after a system failure.
Transactional: Messages can be bunched into “all or nothing” units for delivery.
2. Transactions:
Transactional messaging makes sure that messages are sent or received only when a related task
(like a database update) is successfully completed. If the task is canceled, the message is not
sent, keeping everything consistent and reliable.
3. Clustering:
MOM server clustering improves reliability and
scalability. If one server fails, others handle the
queues, ensuring continuous communication. It
also balances the workload across servers,
distributing client requests to prevent any single
server from being overloaded.
4. Two-way messaging:
Although MOM is typically asynchronous, it can also support synchronous communication. In
this case, the sender sends a request message to the receiver and waits for a reply on a specified
reply queue. This approach is often used in enterprise systems because it integrates easily with
existing applications, works across various platforms (including legacy systems), and leverages
existing investments in messaging technology without requiring complex changes.
Publish subscribe:
Publish–subscribe messaging extends MOM to support communication between multiple
publishers and subscribers using topics. Publishers send messages to a topic, and all active
subscribers listening to that topic receive the message. Multicast-based systems, like TIBCO’s
Rendezvous, send a single copy of the message over the network, improving performance and
scalability compared to point-to-point solutions, especially in high-throughput scenarios.
Topics:
Hierarchical topic naming in publish–subscribe systems uses structured strings with “/”
separators and supports wildcards like * and ** for flexible subscriptions. This allows subscribers
to receive messages from multiple topics or entire branches dynamically without changing their
subscription as new topics are added.
5. Application Server:
Following are the tiers of application server
1. Client Tier: In a web application, the client tier typically comprises an Internet browser that
submits HTTP requests and downloads HTML pages from a web server.
2. Web Tier: The web tier runs a web server to handle client requests. When a request arrives,
the web server invokes web server-hosted components such as servlets, Java Server Pages
(JSPs) or Active Server Pages (ASPs) depending on the flavor of web server being used.
3. Business Component Tier: The business components comprise the core business logic for the
application. The business components are realized by for example Enterprise JavaBeans (EJB)
in JEE, .NET components or CORBA objects.
4. Enterprise Information Systems Tier: This typically consists of one or more databases and
back-end applications like mainframes and other legacy systems.
• Threading and Caching: Allocates threads and maintains caches of entity beans.
• Connection Pooling: Manages a pool of database connections for efficient resource access.
Chapter 5
1. Service-Oriented Systems
The shift to service-oriented systems is driven by the need for better integration of
applications and business systems, moving away from traditional paper-based methods to
electronic communication via the Internet and Web services.
Basic principles:
1. Boundaries Are Explicit
The first tenet emphasizes that services are independent applications requiring careful
design to manage boundaries that can affect performance and complexity. To address
these challenges, services should be designed with simplicity in mind, featuring
straightforward interfaces and minimal shared assumptions to enhance usability for
remote developers.
2. Services Are Autonomous
a. Services are independent applications, not tightly bound components.
c. Policies help generate compatible code and enable client applications to adapt
to different service providers.
Web Services:
• Web services are integration technologies designed to address the needs of service-oriented
architectures (SOA).
• They focus on simplicity, interoperability, and standardization across various software vendors.
• Web services use metadata to describe and discover services and define policies for
things like security and reliability.
• WS-Policy and WS-Security Policy are used to specify security and reliability
requirements for services.
• Purpose: WSDL is used to describe Web services, including their operations, parameters,
and interfaces.
• Structure: WSDL documents describe services, such as the StockQuoteService, and
include information about messages, operations, and bindings.
• Example: The StockQuoteService offers the operation GetLastTradePrice, which takes a
stock symbol as input and returns the last traded price as a float.
WSDL Example:
• Operation: GetLastTradePrice
• Input: Stock symbol (string)
• Output: Last traded price (float)
• Tool Support: Tools like Visual Studio, Eclipse, and WebSphere automatically generate
WSDL from method definitions and make it easier for developers to integrate services.
• While WSDL is useful for defining services, it may encourage developers to treat services
as remote methods, rather than embracing the richer, message-based interaction model
that Web services provide.
Middleware protocols often face connectivity issues on the open Internet due to firewall
restrictions, leading Web services to use HTTP as a transport layer. WS-Security addresses
resulting security concerns with cryptographic mechanisms for authentication, encryption,
and integrity, while WS-ReliableMessaging and transaction standards like WS-
AtomicTransactions and WS-BusinessActivity ensure reliable communication and
coordinated application integration.
Chapter 6
Message Brokers
2. Motivating Example:
• Legacy Systems: Consider an organization with four legacy business systems, each
storing customer information in different formats. To update customer data, the
organization decides to create a web component that passes updated customer data to
each system using MOM.
3. Message Transformation:
• Each legacy system has an interface component that reads messages, transforms the
data into the system’s specific format, and invokes the system's API to update customer
records.
• Tight Coupling: The systems must agree on a message format, which creates tight
coupling. Any changes in the message format require updates across multiple
components, making it complex to manage.
• Message Broker Approach: A message broker decouples the systems by taking over the
responsibility of message format transformation. The web component sends the data in
the common format to the broker, which then transforms the data into the appropriate
format for each legacy system.
• Benefits:
o Reduces the complexity in the web and legacy components, as the
transformation logic is centralized within the broker.
o Changes to the message format only require modifications in the broker
5. Advanced Features of Message Brokers:
Business processes in modern enterprises often involve complex interactions between multiple
systems, requiring seamless integration and reliable transaction management.
1. Simplifying Complexity
o A message broker centralizes transformations, allowing applications to send
messages in their native formats while converting them to target formats
internally.
o This reduces tight coupling between applications and simplifies endpoint
changes.
2. Drawbacks of Message Brokers
o Hidden Complexity: The spaghetti architecture still exists within the broker, with
intricate dependencies captured in its transformations.
o Performance Bottlenecks: Brokers can slow down communication and require
complex, costly setups for scaling, such as clustering and replication.
To address these limitations, an enterprise data model (canonical data model) serves as a
shared format for all message transformations. Applications transform their data to this
standard format, enabling scalable and modifiable integration without relying entirely on
message brokers. For example, a canonical customer data format can standardize
transformations across all business systems.
1. Source application transforms local customer data into canonical customer information
format.
2. Source sends message to target with canonical message format as payload.
3. Target receives message and transforms the canonical format into its own local
customer data representation. This means that each end point (business application)
must know
4. How to transform all messages it receives from the canonical format to its local format
5. How to transform all messages it sends from its local format to the canonical format
1. Designing the model: Creating a common data model for all systems can be difficult, especially
in an organization with diverse, legacy systems.
2. Industry standards: In some cases, external systems or business partners may use incompatible
formats, making it impossible to establish a single canonical format across the entire supply
chain. In such cases, industry standards like RosettaNet or ebXML can be useful for defining
common formats.
3. Incremental adoption: Large organizations rarely have the luxury of designing their enterprise
data model upfront. It is often adopted incrementally, which can delay its full benefits.
1. Introduction to ESB
o Initially, the term may have confused some, as it doesn’t refer to anything related to
software integration but is an acronym for integration middleware technology.
2. General Definition
▪ Event-driven mechanisms.
o ESBs are responsible for connecting various system endpoints using different protocols.
o They typically serve as a messaging hub to facilitate communication and data exchange
in enterprise-level applications.
4. Conclusion
Chapter 7
1. Role of an architect
• Work with the requirements team: The requirements team elicits functional
requirements, while the architect ensures system needs and quality attributes are clearly
defined and understood.
• Work with various application stakeholders: Architects ensure stakeholder needs,
including business and technical requirements, are understood and integrated into the
application design.
• Lead the technical design team: The architect leads a design team, comprising system
designers (or on large projects, other architects) and technical leads to produce the
architecture blueprint.
• Work with the project management: The architect works closely with project
management, helping with project planning.
2. Steps of Architecture Design process
1. Determine Architectural Requirements: This involves creating a statement or model of the
requirements that will drive the architecture design.
2. Identifying Architecture Requirements
2. Medium: this requirement will need to be supported at some stage, but not necessarily in the
first/next release.
3. Low: this is part of the requirements wish list. Solutions that can accommodate these
requirements are desired, but they are not the drivers of the design.
Prioritization gets trickier in the face of conflicting requirements. Common examples are:
Reusability of components in the solution versus rapid time-to-market. Making components
generalized and reusable always takes more time and effort.
Minimal expenditure on COTS products versus reduced development effort/ cost. COTS products
mean you must develop less code, but they cost money.
2.
3. Architecture Design
The architecture design process involves iteratively selecting proven patterns and defining components
within a framework, resulting in architecture views and a design document detailing decisions, rationale,
and risks, relying heavily on experience.
Properties:
1. Separation of concerns: Presentation, business and data handling logic are clearly
partitioned in different tiers.
2. Synchronous communications: Each tier waits for a response from the other tier before
proceeding.
3. Flexible deployment: There are no restrictions on how a multi-tier application is deployed.
Quality Attributes:
1. Availability: Servers in each tier can be replicated, so that if one fails, others remain
available. Overall, the application will provide a lower quality of service until the failed
server is restored.
2. Failure handling: If a client is communicating with a server that fails, most web and
application servers implement transparent failover, redirecting the client request to a live
replica server without its knowledge.
3. Modifiability: Separation of concerns improves modifiability by isolating presentation,
business, and data logic, allowing changes within one tier without affecting others.
4. Performance: This architecture is fast, but it’s important to consider server capacity,
connection speed, data size, and reducing the number of calls between tiers.
5. Scalability: As servers in each tier can be replicated, and multiple server instances run on the
same or different servers, the architecture scales out and up well.
• Messaging:
Properties:
1. Asynchronous communications: Clients send requests to the queue, where the message is
stored until an application removes it.
2. Configurable QoS: The queue can be configured for high-speed, nonreliable or slower,
reliable delivery.
3. Loose coupling: There is no direct binding between clients and servers.
• Quality attributes:
1. Availability: Physical queues with the same logical name can be replicated across different
messaging server instances. When one fails, clients can send messages to replica queues.
2. Failure handling: If a client is communicating with a queue that fails, it can find a replica
queue and post the message there.
3. Modifiability: Messaging is inherently loosely coupled, and this promotes high modifiability
as clients and servers are not directly bound through an interface. Self-describing,
discoverable message formats can help reduce this dependency on message formats.
4. Performance: Message queuing technology can deliver thousands of messages per second.
5. Scalability: Queues can be hosted on the communicating endpoints or be replicated across
clusters of messaging servers hosted on a single or multiple server machines. This makes
messaging a highly scalable solution.
Publish–Subscribe:
• Properties:
1. Many-to-Many messaging: Published messages are sent to all subscribers who are registered
with the topic.
2. Configurable QoS: Communication can be point-to-point, sending separate messages to each
subscriber, or broadcast/multicast, sending one message to all subscribers.
3. Loose Coupling: As with messaging, there is no direct binding between publishers and
subscribers. Publishers do not know who receives their message, and subscribers do not
know which publisher sent the message.
• Quality attributes:
1. Availability: Topics with the same name can be replicated across server clusters, so if one fails,
publishers send messages to replica queues.
2. Failure handling If a publisher is communicating with a topic hosted by a server that fails, it can
find a live replica server and send the message there
3. Modifiability: Publish–subscribe is inherently loosely coupled, and this promotes high
modifiability. New publishers and subscribers can be added to the system without changing the
architecture or configuration.
4. Performance Publish–subscribe can deliver thousands of messages per second, with nonreliable
messaging faster than reliable.
5. Scalability: Topics can be replicated across clusters of servers hosted on a single or multiple
server machines.
Broker:
Properties:
1. Hub-and-spoke architecture: The broker acts as a messaging hub, and senders and receivers
connect as spokes. Connections to the broker are via ports that are associated with a specific
message format.
2. Performs message routing: The broker embeds processing logic to deliver a message received on
an input port to an output port. The delivery path can be hard coded or depend on values in the
input message.
3. Performs message transformation: The broker logic transforms the source message type
received on the input port to the destination message type required on the output port.
Quality Attributes:
1. Availability: To ensure high availability, brokers must be replicated, often using similar
mechanisms to messaging and publish-subscribe server clustering.
2. Failure handling: Brokers validate messages through typed input ports, discarding incorrect
formats, and with replicated brokers, senders can switch to a live broker if one replica fails.
3. Modifiability: Brokers isolate transformation and routing logic from senders and receivers,
improving modifiability by allowing changes without impacting them.
4. Performance: Brokers can potentially become a bottleneck, especially if they must service
high message volumes and execute complex transformation logic.
5. Scalability: Clustering broker instances makes it possible to construct systems scale to handle
high request loads.
Process Coordinator:
Properties:
1. Process encapsulation: The process coordinator defines and manages the sequence of steps
in a business process, making it easier to understand and modify by initiating the process,
calling servers in order, and emitting results.
2. Loose coupling: Server components are unaware of their role or the process order; they
simply provide services that the coordinator calls as needed in the business process.
3. Flexible communications: Communications between the coordinator and servers can be
synchronous or asynchronous. For synchronous communications, the coordinator waits until
the server responds. For asynchronous communications, the coordinator provides a callback
or reply queue/topic and waits until the server responds using the defined mechanism.
Quality Attributes:
4. Component Allocation in Architecture Design
Once an overall architecture framework is selected, the next task is to define the major
components that make up the design. The framework sets the communication patterns between
components, and additional considerations must include:
• Identify Major Components: Define the major application components and how they fit into the
framework.
• Define Interfaces and Services: Specify the services each component supports.
• State Component Responsibilities: Clarify what each component will do when receiving a
request.
• Consider Distribution: Identify which components are suitable for distribution across multiple
servers.
• Minimize Dependencies: Strive for loosely coupled components, so changes to one component
do not affect others.
• Design for Cohesion: Components should have a small, well-defined set of responsibilities,
minimizing maintenance and testing efforts.
• Isolate Dependencies: Reduce the number of components relying on middleware or COTS
technologies, making upgrades easier.
5. Validation:
Architecture Validation
The goal of the validation phase is to ensure the architecture is fit for its intended purpose.
Since a design can't be directly executed or tested, validation is crucial to identify potential
flaws before implementation.
Validation Techniques:
1. Manual Testing: Test scenarios are used to assess the architecture manually.
2. Prototyping: A prototype is built to simulate a simplified version of the application and test its
ability to meet requirements.
Chapter 8