Architectural Patterns and Anti-Patterns Questions

Architecture-level patterns and the anti-patterns that signal a wrong turn. Patterns: layered and n-tier architecture, including where cross-cutting concerns like authentication, rate-limiting and tracing belong, dependency injection trade-offs, and thin-versus-fat controller design; hexagonal (ports and adapters) and clean architecture; CQRS and event sourcing; backend-for-frontend; plugin (microkernel) extension models; and the coupling, cohesion, encapsulation and separation-of-concerns principles behind them, including when each applies and what it costs. Anti-patterns: distributed monolith, chatty services, shared-database coupling, cyclic service dependencies, leaky abstractions that expose internal schemas, and golden-hammer pattern adoption. Covers the detection signals (deploy coupling, call-graph fan-out, change amplification, trace evidence), incremental remediation, and architecture governance that keeps smells from recurring. This is about diagnosing and fixing the smell in an existing design, not the monolith-versus-microservices decision itself.

MediumSystem Design
129 practiced

A customer needs significant customization, but your product is built around a single core codebase shared by every customer. Propose an architecture and delivery approach that balances customizability with maintainability: consider feature flags, plugin or extension models, configuration schemas, and release management.

EasyTechnical
74 practiced

Describe encapsulation in the context of service APIs and data models. Explain how exposing internal data structures (for example, database-schema details) in service responses can lead to production issues, and how stronger encapsulation would have prevented them. Include one example of an enforcement mechanism.

MediumTechnical
74 practiced

What's the difference between loose and tight coupling between services, and why does it matter for how independently teams can ship? Name a few concrete techniques you'd use to loosen coupling in an existing tightly-coupled system, and describe how you'd actually measure or surface coupling levels across a codebase or service map today.

EasyTechnical
91 practiced

Describe a typical three-tier (multi-tier) layered web architecture: presentation/UI, application/business logic, and persistence/data. For each tier, name its responsibilities, then trace how a single request flows through the system, from the client through ingress, load balancing, and the application tier down to the data tier and back. What are the trade-offs of this architecture (scalability, deployment complexity, testability) compared to a simpler two-tier design or a flatter, event-driven one?

MediumTechnical
81 practiced

In a layered backend, concerns like authentication, rate-limiting, and tracing apply to nearly every request. If each service implements them independently you get drift and duplicated bugs. Where architecturally should this kind of cross-cutting logic live, what are the trade-offs of the placement options, and how do you keep the behavior consistent as new services are added?

Unlock Full Question Bank

Get access to all 19 Architectural Patterns and Anti-Patterns interview questions and detailed answers.

Sign in to Continue

Join thousands of developers preparing for their dream job.