Reasoning About Software Architecture

Software architecture concerns a system's significant structures, their relationships, and the principles guiding its design and evolution. You use architectural reasoning when a decision affects several responsibilities, important system qualities, or the cost of future change. An architecture exists in the implemented system; diagrams and written decisions help you understand and evaluate it.

Recognizing architectural significance

A decision is architecturally significant because of its consequences. Choosing where access rules are enforced may affect security, testing, and every operation that handles protected information. Renaming a temporary variable usually affects a much smaller area. The same technical choice can have different significance in different systems: changing a data format becomes architectural when several independently maintained parts depend on it.


Decision

Typical significance

Reason

Set a shared rule for checking access

Architectural

Several responsibilities depend on consistent enforcement

Restrict which responsibilities may access stored orders

Architectural

The restriction shapes dependencies and future changes

Rename a variable inside one function

Local implementation

The change normally preserves externally visible relationships


Architecture connects technical decisions to the concerns of stakeholders. Users may care about response time, while maintainers care about safe changes. Explaining these concerns makes a decision easier to evaluate than simply naming a preferred technology.

Representations answer different questions

An architectural view deliberately leaves some information out. A structural view can show responsibilities and permitted dependencies. A runtime view can show interactions during an operation. A deployment view can show where software executes. These representations should describe compatible aspects of the same system.


Order handling has permitted calls to inventory rules and order storage.


An arrow needs a stated meaning. It might represent a permitted call, a message, or a dependency; these meanings are not interchangeable. A diagram showing permitted calls does not establish their frequency or duration.



Evaluate qualities under stated conditions

A quality attribute describes how well a system operates or accommodates change, such as its performance, security, or modifiability. A useful requirement gives the operating conditions and an observable criterion. For example, a response-time requirement should identify the operation, workload, measured statistic, and acceptable limit.


For a simplified request whose processing stages run sequentially, with fixed durations and no overlap, the timing model is


Trequest=∑i=1nti+Tinteraction.T_{\text{request}}=\sum_{i=1}^{n}t_i+T_{\text{interaction}}.


Here, tit_i is the duration of processing stage ii, and TinteractionT_{\text{interaction}} is the total additional time spent communicating between stages. Include every contribution once. Waiting or other delays require additional terms if the model has not already included them.


Example: A hypothetical operation has fixed processing durations of 48 ms and 72 ms, plus 12 ms of interaction time. Its predicted total is 48+72+12=132 ms48+72+12=132\ \text{ms}, leaving 150−132=18 ms150-132=18\ \text{ms} below a 150 ms limit. This conclusion applies to the stated model and conditions.



Architectural choices often improve one quality while consuming resources or making another quality harder to achieve. Check hard constraints before ranking feasible alternatives. A faster proposal may still exceed a memory limit. Record the decision rationale so that a later change in workload or requirements can trigger a meaningful reassessment.

What to remember

  • Judge architectural significance by system-wide consequences.
  • Use complementary representations with explicit meanings.
  • Evaluate qualities against measurable requirements and stated conditions.
  • Treat a model's prediction as conditional on its assumptions.
  • Compare trade-offs only after checking hard constraints.

Example: Choosing a Request-Handling Proposal

A ticket-booking team compares two software architecture proposals. The latency budget is the maximum permitted end-to-end request time: 200 ms. Peak memory use must also remain at or below 512 MiB.


For this exercise, treat the predicted processing durations and memory values as exact for one specified operating scenario. Processing stages run sequentially, and the listed interaction time is additional time across the whole request. There is no overlap or other delay. The table contains individual fixed durations, not percentile measurements.


Contribution

Proposal A

Proposal B

Validate request

35 ms

35 ms

Check availability

75 ms

45 ms

Record booking

65 ms

65 ms

Total additional interaction time

20 ms

40 ms

Peak memory use

440 MiB

590 MiB


a) Calculate the predicted end-to-end request time for each proposal.


Step 1: Add the processing durations. Proposal A's processing subtotal is ________, obtained from 35+75+6535+75+65. Proposal B's processing subtotal is ________, obtained from 35+45+6535+45+65.


Step 2: Add each proposal's total interaction time once. It already covers all interactions, so multiplying it by the number of processing stages would count time that the model does not specify.


TA=(35+75+65)+20=195 ms,TB=(35+45+65)+40=185 ms.\begin{aligned} T_A&=(35+75+65)+20=195\ \text{ms},\\ T_B&=(35+45+65)+40=185\ \text{ms}. \end{aligned}


The predicted request times are 195 ms for Proposal A and 185 ms for Proposal B.


b) Determine which proposals satisfy both hard constraints under the stated model.


Step 1: Compare each request time with the 200 ms limit. Proposal A's response-time headroom is ________, found from 200−195200-195. Proposal B's response-time headroom is ________, found from 200−185200-185. Both satisfy the timing requirement.


Step 2: Compare peak memory use with the 512 MiB limit.


HA=512−440=72 MiB,HB=512−590=−78 MiB.\begin{aligned} H_A&=512-440=72\ \text{MiB},\\ H_B&=512-590=-78\ \text{MiB}. \end{aligned}


The negative memory headroom means Proposal B exceeds the limit by 78 MiB. Both requirements must hold for the same proposal.


Proposal A satisfies both constraints. Proposal B fails the memory constraint. This is a conclusion about the supplied scenario and model, rather than proof about all possible workloads.


c) Calculate Proposal B's percentage reduction in response time relative to Proposal A, to one decimal place. Does that improvement justify selecting B under the stated requirements?


Step 1: Find the absolute reduction. The difference 195−185195-185 is ________. Use Proposal A's time as the reference because the question asks for the reduction relative to A.


Step 2: Divide the reduction by the reference time and convert to a percentage.


Reduction=195−185195×100%=5.128…%≈5.1%.\text{Reduction}=\frac{195-185}{195}\times100\%=5.128\ldots\%\approx5.1\%.


Proposal B reduces predicted response time by 5.1% relative to Proposal A. However, its lower response time does not remove its 78 MiB memory excess. Select Proposal A from these two proposals under the stated requirements. Selecting B would require a justified change to the proposal or the memory constraint, followed by reassessment.

A university registration system handles enrolment, fee payments, and transcript requests. Which proposed change most clearly requires architectural reasoning because of its consequences across these responsibilities?

Choose an answer

Create a free account to get started

Unlock full course notes by signing up

  • Video lessons taught by top educators
  • Practice questions with guided solutions
  • Written review notes for reference
  • Expert answers anytime from course tutors

A review team is organizing documentation for a new booking system. Match each term to the description that correctly identifies its role in architectural reasoning.

Match each term
A.

A property describing how well a system operates or accommodates change

B.

Significant system structures, their relationships, and principles guiding design and evolution

C.

Reasons, evidence, assumptions, and trade-offs supporting the selected alternative

D.

A representation focused on selected concerns, such as permitted dependencies or runtime interactions

Software architecture

Decision rationale

Architectural view

Quality attribute

Create a free account to get started

Unlock full course notes by signing up

  • Video lessons taught by top educators
  • Practice questions with guided solutions
  • Written review notes for reference
  • Expert answers anytime from course tutors

A booking request has a 240 ms response-time limit. Its three sequential processing stages take fixed durations of 45 ms, 70 ms, and 55 ms. Five additional interactions occur sequentially, each taking the same duration. There are no other delays or overlapping operations. What is the maximum permitted duration of each interaction, in ms, to the nearest whole millisecond?

Create a free account to get started

Unlock full course notes by signing up

  • Video lessons taught by top educators
  • Practice questions with guided solutions
  • Written review notes for reference
  • Expert answers anytime from course tutors

Extra Practice