Föreläsning 4 - Quality Characteristics of IoT-Based Systems Flashcards
(16 cards)
What does functionality mean in software architecture? -
- Functionality means what the system is supposed to do — its main tasks or purpose.
- It doesn’t control or determine the architecture. → You can build many different architectures to support the same functionality.
- Functionality and quality attributes (like performance, security, etc.) are separate ideas — they don’t affect each other directly.
What are quality attribute considerations? -
If a functional requirement is “when the user is home, → thermostat should heat the apartment if temp is below…”. Quality attribute:
- Performance – How fast it heats.
- Availability – How often it fails & how fast it’s fixed.
- Usability – How easy it is to learn user preferences.
Three problems with quality attributes and solutions -
- Definitions aren’t testable (saying a system is “modifiable” means little without specifics).
- Overlapping concerns (It’s unclear which attribute an issue belongs to (e.g., system failure from an attack)).
- Different vocabularies (each quality attribute area uses its own terms).
Solutions: Use quality attribute scenarios to make attributes clear and testable. Discuss each attribute’s core concerns to unify understanding.
Six parts of a quality attribute scenario -
- Stimulus (what triggers the system).
- Stimulus source (who/what causes the stimulus).
- Environment (situation/context the system is in when it responds).
- Artifact (system/components that react).
- Response (what system does after being triggered).
- Response measures (how we judge if the response was good).
Name four IoT systems quality attributes -
Availability, performance, security and usability.
Availability -
The system is ready and working when needed. It includes the ability to handle and recover from faults within a time limit. Related to:
- Security (e.g. denial-of-service attacks).
- Performance (slow response may look like failure).
- Safety (recovering from hazardous states).
Detect faults key tactics -
discover when something in the system doesn’t work as intended.
- Monitor (central concept for health checking on other parts of the system).
- Heartbeat (common in real-time/IoT systems to show a process is alive).
- Ping/Echo (periodic message exchange occurs between a monitor and a process being monitored).
- Exception Detection (detection of a system condition that alters the normal flow of execution).
Recover from faults, key tactics -
Tactics used to recover when a fault occurs.
- Rollback (returning to the previous working state).
- Retry (try the failed operation again).
- Graceful degradation (system continues to function, even with reduced capabilities).
- Redundant spare (use backup components).
- Exception handling (dealing with errors as they occur).
- Reconfiguration (adjusting the system to work around the fault).
Prevent faults, key tactics -
- Removal from service (temporarily place a system component in an out-of-service state to mitigate potential system failure).
- Predictive model (use performance metrics to predict the onset fault).
- Exception prevention (Using methods to avoid errors (exceptions) before they happen - instead of just reacting to them.).
Performance -
is about timing. Events occur, and the system must respond to them.
- Event arrival patterns: periodic, stochastic and sporadic.
- Event servicing:
- Latency - the time taken between arrival and response.
- Jitter - variation in latency.
- Throughput - number of requests processed per second.
Performance scenarios -
- source of stimulus (internal/external).
- Stimulus (event arrival, based on patterns).
- Artifact (system).
- Environment (normal mode; overload mode).
- Response (changes level of service, processes stimuli).
- Response measures (latency, jitter, miss rate, data loss).
Control resource demand, tactics -
tactics to ensure that the system performs efficiently by controlling and managing resource usage and the demand placed on the system.
- Manage work requests (reduce the number of requests coming into the system).
- Limit event response (cap the number of events processed, policies for ignoring events).
- Prioritise events (ensure important events are processed rapidly).
Tactics to meet performance requirements -
methods to improve system performance.
- Caching (store frequently used data for quick access, reducing slow data fetching).
- Load Balancing (distribute traffic across servers to optimize resources and speed up responses).
- Parallelism/Concurrency (perform multiple tasks at once to maximize resource use and reduce response time).
Attribute-Driven design -
is a methodology for designing software architecture based on quality attributes (e.g., performance, scalability, security). Instead of focusing solely on functional requirements, ADD emphasises the architectural drivers that shape the system’s structure.
Key concepts of ADD -
- Identify drivers: Consider quality attributes, constraints, and functional requirements.
- Decompose system: Break the architecture into subsystems and components based on drivers.
- Apply tactics/patterns: Use design patterns (e.g., microservices) to meet goals.
- Evaluate design: Assess the architecture for effectiveness.
Why use ADD? -
Ensures architectural decisions align with business goals. Helps prioritise trade-offs between competing quality attributes. Provides a structured approach to designing complex systems.