## What does the **Structural View** of a software architecture show? --- ๐Ÿ—๏ธ It is a **static view** (like a class diagram) that shows component types, ports, connectors, and architecture stereotypes. %%% What is the primary focus of the **Dynamic View** in software architecture? --- ๐ŸŽฌ It shows all possible **interactions** between objects in the system. %%% What does the **Deployment View** represent? --- ๐ŸŒ It shows the **physical configuration** of the system, including how software is mapped to hardware. %%% What are the defining characteristics of a **Sequential Software Architecture**? --- ๐Ÿงต 1. **Single thread** of control. 2. **All objects are passive**. 3. Used by cyclic executives. %%% Name three major benefits of **Concurrent Software Architectures**. --- ๐Ÿš€ 1. Threads can run while others are **blocked** for events. 2. Supports **multi-core** or distributed systems. 3. Multiple input streams can be handled in **parallel**. %%% How do components in a **Component-Based Architecture** interact? --- ๐Ÿ”Œ They are treated as **black boxes** that communicate through **well-defined interfaces**. %%% In a Component-Based system, what is a **Subsystem**? --- ๐Ÿงฉ A **Composite Component** (a component that contains other components). %%% ## When applying **Separation of Concerns**, what is the rule regarding objects on **separate nodes**? --- ๐ŸŒ They should be placed in **separate subsystems**. %%% Where should **Control objects** and the **Entity objects** they interact with be located? --- ๐Ÿ“ฆ They should both be part of the **same subsystem**. %%% ## What is the rule for **Clients and Services** in subsystem structuring? --- โ†”๏ธ They should be in **separate subsystems**. %%% What are the defining features of a **Control Subsystem**? --- ๐Ÿ•น๏ธ - Receives inputs from and sends outputs to the **external environment**. - It is usually **state-dependent**. - It interacts with other subsystems as needed. %%% What is the role of a **Coordinator Subsystem**? --- ๐Ÿค It coordinates the actions of **multiple control subsystems** in a complex system. %%% What may a **User-Interaction Subsystem** contain for performance optimization? --- ๐Ÿ—„๏ธ It may contain **Entity objects** for local storage and **caching**. %%% What is the difference between **Data Collection** and **Data Analysis** subsystems? --- ๐Ÿ“Š - **Data Collection**: Gathers data from the environment and may perform **data reduction**. - **Data Analysis**: Provides **reports and analysis**; often operates in non-real-time. %%% How does a **Service Subsystem** differ from other subsystems in terms of behavior? --- ๐Ÿ› ๏ธ It **does not initiate actions** on its own; it only provides services to other subsystems upon request. %%% What is the interface rule regarding **External Components**? --- ๐Ÿ”Œ An external component should only interface to **one single subsystem**. %%% ## How does the scale of a **Design Pattern** compare to a single Class? --- ๐Ÿ—๏ธ It is a **larger-grained** form of reuse; it involves **multiple classes** and their specific interactions rather than just one. %%% What are **Idioms** in the context of software patterns? --- ๐Ÿ’ป They are **low-level patterns** tailored to a **specific programming language**. %%% What is the difference between **Design Patterns** and **Architectural Patterns**? --- ๐Ÿ“ - **Design Patterns**: A small group of collaborating objects (e.g., Gang of Four). - **Architectural Patterns**: Larger-grained, addressing the structure of **major subsystems**. %%% What is a **Design Anti-Pattern**? --- โš ๏ธ **Bad code** or poor design solutions that are seen repeatedly. %%% What is the difference between **Strict** and **Loose** Layered architectures? --- ๐Ÿฅž - **Strict**: A layer can only use services from the layer **immediately below** it. - **Loose**: A layer can use services from **any** lower layer. %%% ## How does **Centralized Control** manage system inputs and outputs? --- ๐ŸŽฏ There is only **one control component**: all inputs flow into it, and all outputs originate from it (e.g., a Nuclear Power Station). %%% ## What defines **Distributed Collaborative Control**? --- ๐Ÿค Multiple peer controllers manage subsets of the system and **exchange events** for coordination (e.g., Air Traffic Control). %%% ## What is the key restriction in **Distributed Independent Control**? --- ๐Ÿงฑ While control is distributed, there is **no communication** or coordination between the various control components (e.g., Railway crossings). %%% ## What characterizes a **Hierarchical Control** pattern? --- ๐Ÿ‘‘ A **top-level coordinator** component sends commands to and receives responses from lower-level distributed controllers (e.g., a Telephone Switch). %%% In a **Master/Slave** pattern, what are the three main rules for the Slaves? --- โ›“๏ธ 1. Slaves **do not interact** with each other. 2. Slaves **do not have** their own control objects. 3. They only respond to the Master, who integrates their results. %%% ## What occurs in the **Synchronous Object Access** pattern? --- ๐Ÿค Two or more **active objects** share data through a **passive object**. Because the data is shared, **mutual exclusion (mutex)** is strictly required. %%% What is a classic example of the **Synchronous Object Access** pattern? --- ๐Ÿญ The **Producer-Consumer** problem (where both access a shared buffer entity). %%% How does the **Asynchronous Message Communication** pattern affect the sender? --- ๐Ÿ“จ The sender (Producer) sends the message and **continues immediately** without waiting. Messages may queue at the consumer. %%% What is a major risk of **Asynchronous Message Communication**? --- โš ๏ธ If the producer sends data faster than the consumer can receive it, **messages will be dropped** (buffer overflow). %%% How does **Bidirectional Asynchronous** messaging differ from standard asynchronous messaging? --- ๐Ÿ”„ The sender needs a reply but **not immediately**. Multiple messages can be sent before a response (like an ACK) is required. **Example:** TCP protocol. %%% What happens to a client during a **Synchronous Message with Reply**? --- ๐Ÿ›‘ The client sends a message and **blocks** (stops execution) until the server processes the request and sends a reply back. **Examples:** RPC (Remote Procedure Call) or RMI. %%% In the **Asynchronous Message with Callback** pattern, what is the limit on outstanding requests? --- ๐Ÿ“ž Only **one request** can be outstanding at a time. The client continues running but expects a response via a callback later. %%% What is the primary benefit of the **Synchronous Message without Reply** pattern? --- โฑ๏ธ It **throttles the producer**: the producer blocks until the consumer receives the message, preventing the producer from overwhelming a slow consumer. --- ## What is the main advantage and disadvantage of **Asynchronous Communication**? โš–๏ธ - **(+) More Parallelism**: The sender doesn't wait and keeps working. - **(-) Buffer Loss**: Data can be lost if the sender is faster than the receiver. %%% Why does **Synchronous Communication** involve less data copying on the same node? --- ๐Ÿ“‹ Because the sender and receiver can **share the same address space**, whereas asynchronous usually requires copying data into a message buffer and then out again. %%% Is the "reduced parallelism" of Synchronous Communication always a disadvantage? --- ๐Ÿค” **Not necessarily.** While it reduces parallel execution, the resulting "blocking" behavior naturally synchronizes the timing of the two components (throttling). %%% ## What are the two types of **Transparency** provided by a **Broker Pattern**? --- ๐Ÿ•ต๏ธ 1. **Location Transparency**: The client only needs to know the broker's location; the server can move. 2. **Platform Transparency**: The server can run on different hardware or software platforms. %%% ## In a **Broker Pattern**, what are the two ways a Broker can handle a client's request? --- ๐Ÿ”„ 1. **Query once**: The broker provides the server's information, and the client contacts the server directly. 2. **Intermediary**: The broker acts as a middleman and forwards the requests to the server. %%% What is the primary "cost" or disadvantage of using a **Broker**? --- โณ **Overhead**: The client must perform an extra step (asking the broker) before it can actually access the server. %%% What is the difference between **Broadcast** and **Subscription** message patterns? --- ๐Ÿ“ก - **Broadcast**: Messages are sent to **everyone**; recipients must filter out what they don't want. - **Subscription**: Recipients **register** for specific messages; they only receive what they asked for. %%% ## Which well-known design pattern is used to implement **Subscription/Notification**? --- ๐Ÿ”” The **Observer Pattern**: A publisher sends messages to a group without needing to know specific individual recipients. %%% What is the main downside of the **Broadcast** pattern in a network? --- ๐Ÿšฆ It creates **more message traffic**, as data is pushed to every potential recipient regardless of interest.