CPSA-F Certified Professional for Software Architecture – Foundation Level Practice Questions
Prepare for CPSA-F with more than an answer.
- Level
- Foundation
- Valid for
- Lifetime
Domains covered on the exam 6
- Basic Concepts of Software Architecture17%
- Requirements and Constraints6%
- Design and Development of Software Architectures40%
- Specification and Communication of Software Architectures26%
- Analysis and Assessment of Software Architectures9%
- Examples of Software Architectures6%
- 1
True or False: Conway's Law suggests that the communication structure of an organization is a significant constraint that tends to shape the architecture of the systems it builds.
Show answer details
Correct answer: A
This statement is true. Conway's Law famously states that organizations which design systems are constrained to produce designs which are copies of the communication structures of these organizations. This highlights the powerful influence of team structure and organizational communication paths on the final software architecture.
- 2
An architect is designing a system where reads are 100 times more frequent than writes. The data, once written, does not need to be immediately available for reading, but query performance is critical. This scenario suggests a potential fit for which architectural pattern?
Show answer details
Correct answer: A
CQRS is a pattern that separates the models for updating (Command) and reading (Query) data. This is ideal for scenarios with very different read/write patterns. It allows the read model to be highly optimized for queries (e.g., using denormalized views), while the write model is optimized for transactional consistency. The tolerance for eventual consistency ('does not need to be immediately available') is a classic indicator for a CQRS-based solution.
- 3
A team is building a complex reporting module. One developer creates a
ReportGeneratorclass that handles connecting to the database, fetching user data, fetching sales data, formatting the data into a PDF, and emailing the PDF to a manager. This class is over 2000 lines long. Which design principle has been most clearly violated?Show answer details
Correct answer: B
The Single Responsibility Principle states that a class should have only one reason to change. The
ReportGeneratorclass has multiple responsibilities: data access, data formatting, and notification. A change in the database, the PDF format, or the email system would all require this single class to be modified. This violates SRP and indicates very low cohesion. - 4
An architect is reviewing the following deployment architecture diagram for a web application. The design's goal is to ensure high availability and proper security zoning.
Internet | [Firewall] | ┌─── Public Subnet (DMZ) ─────────────────┐ │ │ │ [Load Balancer] │ │ | | │ [Web Srv 1] [Web Srv 2] │ │ | | │ `--[DB]---´ │ │ │ └─────────────────────────────────────────┘What is the most significant architectural flaw in this diagram?
Show answer details
Correct answer: B
The most critical flaw is placing the database server in the Demilitarized Zone (DMZ). Security best practices dictate that data stores should be in a separate, private subnet with no direct access from the internet. Only the web servers in the DMZ should be able to communicate with the database. Placing the database in the DMZ exposes it to a much higher level of risk if a web server is compromised.
- 5
An architect is trying to analyze the system for potential performance bottlenecks. Which of the following are examples of quantitative, measurable metrics that can be used for this analysis? (Select THREE)
Show answer details
Correct answer: A, C, D
Quantitative analysis relies on objective, numerical measurements. Response time, throughput, and resource utilization (CPU/memory) are all direct, measurable metrics that can be used to identify performance issues. Developer sentiment is a form of qualitative data, valuable for assessing maintainability but not for quantitative performance analysis.
- 6
A financial services company is modernizing its monolithic core banking system. The primary architectural goals are to improve time-to-market for new features and enhance fault isolation between different banking functions (e.g., loans, accounts, transfers). The development team is highly skilled in Java but has limited experience with cloud-native technologies. Which architectural approach best balances these goals and constraints?
Show answer details
Correct answer: B
The Strangler Fig pattern is the optimal choice as it allows for an incremental, risk-managed migration. It directly addresses the goals of improving time-to-market and fault isolation by creating independent services. It also respects the team's Java skills (new services can be in Java) while allowing them to learn containerization gradually. A big-bang rewrite is too risky, a lift-and-shift doesn't solve the core architectural problems, and a modular monolith improves code structure but not independent deployability or fault isolation as effectively.
- 7
During an architecture review for a new distributed logistics platform, the architect presents a plan for handling cross-cutting concerns. The platform will consist of dozens of microservices. Which of the following concerns are best addressed through a globally enforced, consistent strategy rather than being implemented uniquely within each service? (Select THREE)
Show answer details
Correct answer: A, C, E
Cross-cutting concerns are aspects of a system that affect multiple components. Distributed tracing, centralized logging, and security (authN/authZ) are classic examples that require a consistent, system-wide approach to be effective. Inconsistent implementation would render them useless. Business logic and database schemas are specific to the bounded context of an individual service and are not cross-cutting.
- 8
True or False: In a system designed with the Pipes and Filters architectural pattern, a key benefit is that individual filters can be developed and tested in isolation, provided they adhere to the common data format for the pipe.
Show answer details
Correct answer: A
This statement is true. A core advantage of the Pipes and Filters pattern is the decoupling of individual processing steps (filters). Because each filter only depends on the input data format and produces an output in the agreed-upon format, they can be developed, deployed, and tested independently, which enhances modularity and maintainability.
- 9
A software architect is designing a system component that must be extensible without modification. New functionality will be added frequently by different teams. The architect wants to allow new behaviors to be added to the component's core process while avoiding a cascade of
if-elseorswitchstatements. Which design principle is most critical to apply here?Show answer details
Correct answer: C
The Open/Closed Principle states that software entities (classes, modules, functions, etc.) should be open for extension but closed for modification. This directly addresses the requirement to add new functionality without changing the existing, core code, thus avoiding complex conditional logic. Patterns like Strategy or Decorator are common implementations of OCP.
- 10
A new architect joins a project and finds that the
UserServiceis directly instantiating thePostgreSQL_Loggerclass for logging activities. TheOrderServicedoes the same. This has led to difficulties in testing and a desire to switch to a file-based logger in the future. The architect recommends changing the code so that both services depend on anILoggerinterface instead of a concrete class. This change exemplifies the application of which design principle?Show answer details
Correct answer: B
The Dependency Inversion Principle states that high-level modules should not depend on low-level modules; both should depend on abstractions. By changing
UserService(high-level) to depend onILogger(abstraction) instead ofPostgreSQL_Logger(low-level), the architect is directly applying DIP. This decouples the services from the concrete logging implementation, making the system more flexible and easier to test.
