design

Practical resources about design for software engineers.

152 results

Patterns for Maintainable Code

Design patterns are not cookbook recipes — they are a shared vocabulary for discussing solutions to recurring problems. Knowing when to apply (and when to avoid) a pattern is a hallmark of senior engineering.

Browse our catalog of creational, structural, and behavioral patterns. Each entry includes a real-world scenario, UML diagrams, implementation in multiple languages, and a discussion of trade-offs. From Singleton to Outbox, find the right tool for your context.

intermediate

Graceful Degradation Pattern

Degrade functionality instead of failing when dependencies are unavailable. Serve partial results,...

intermediate

Idempotent Consumer Pattern

Process messages from a queue exactly once regardless of duplicates by using idempotent operations,...

intermediate

Identity Map Pattern

Ensure each object is loaded only once per transaction by caching instances by their primary key,...

intermediate

Inbox Pattern

Use a dedicated inbox table or queue to record incoming events or requests, ensuring reliable...

intermediate

Intercepting Filter Pattern

Compose cross-cutting concerns into a chain of pluggable filters that intercept requests and...

advanced

Interpreter Pattern

Define a representation for a language's grammar along with an interpreter that uses the...

advanced

Interpreter Pattern for Domain-Specific Expression Languages

Build a language interpreter that evaluates expressions and rules by representing grammar as...

beginner

Iterator Pattern

Provide a way to access elements of a collection sequentially without exposing its underlying...

intermediate

Iterator Pattern for Custom Collection Traversal in

Provide a way to access elements of an aggregate object sequentially without exposing its...

beginner

Manager Pattern

Encapsulate lifecycle, coordination, and access control for a set of related objects through a...

beginner

Marker Interface Pattern

Use empty interfaces as metadata tags to signal properties or capabilities at compile time and...

intermediate

Materialized View Pattern

Precompute and store expensive query results in a read-optimized cache to avoid repeated costly...

intermediate

Mediator Pattern

Define an object that encapsulates how a set of objects interact. A behavioral design pattern for...

intermediate

Mediator Pattern for Loose Component Coupling in

Reduce chaotic dependencies between UI components by introducing a mediator that centralizes...

intermediate

Memento Pattern

Capture and restore an object's internal state without violating encapsulation. A behavioral design...

intermediate

Memento Pattern for State Snapshot and Restoration

Capture and externalize an object's internal state without violating encapsulation, enabling undo,...

beginner

Mixin Pattern

Add reusable behavior to classes without inheritance by composing methods from shared objects into...

intermediate

Model-View-Presenter (MVP) Pattern

Separate presentation logic from the view by introducing a presenter that intermediates between the...

intermediate

Model-View-ViewModel (MVVM) Pattern

Bind UI components declaratively to a ViewModel that exposes data and commands, enabling automatic...

beginner

Module Pattern

Encapsulate private state and behavior inside a self-contained unit with a public API. A structural...

No results found.