Dabaoshi
Author

Dabaoshi

Practical utilities

50
Articles
0
Likes
160
Views
0
Comments
Recent Articles

Latest from Dabaoshi

50 recent articles
Dabaoshi
Dabaoshi
Aug 13, 2026 · Fundamentals

Design Patterns 23 – Final Overview: Mapping All 23 Patterns onto One Diagram

The article wraps up the "Design Pattern Dissection" series by showing how the 23 GoF patterns appear in JDK, Spring and MyBatis, clarifying the most confusing pattern pairs, warning against over‑design, and presenting a comprehensive map that links each pattern to the seven core design principles.

Design PatternsGoFJava
0 likes · 12 min read
Design Patterns 23 – Final Overview: Mapping All 23 Patterns onto One Diagram
Dabaoshi
Dabaoshi
Aug 12, 2026 · Fundamentals

Why Mediator, Visitor, and Interpreter Are the Rarest Design Patterns (And When to Avoid Them)

This article examines the three least‑used behavioral design patterns—Mediator, Visitor, and Interpreter—by explaining the problems each solves, showing core implementations with order‑page examples, highlighting their narrow applicability, common pitfalls, and why developers should often steer clear of them.

Design PatternsSoftware Architecturebehavioral
0 likes · 12 min read
Why Mediator, Visitor, and Interpreter Are the Rarest Design Patterns (And When to Avoid Them)
Dabaoshi
Dabaoshi
Aug 11, 2026 · Fundamentals

Why the Iterator Pattern Is the Most Used Yet Unnoticed Design Pattern in Java

The article explains how the Iterator pattern, built into Java as Iterable and Iterator interfaces, lets you traverse any collection uniformly without exposing its internal structure, demonstrates the fail‑fast mechanism, and shows when custom collections should implement Iterable.

CollectionDesign PatternIterable
0 likes · 13 min read
Why the Iterator Pattern Is the Most Used Yet Unnoticed Design Pattern in Java
Dabaoshi
Dabaoshi
Aug 11, 2026 · Fundamentals

Command Pattern: Turning Operations into Objects for Undo, Redo, and Queuing

The article explains how the Command pattern encapsulates a request as an object, enabling storage, queuing, undo/redo, and decoupling between request senders and executors, with concrete Java examples and guidance on when the pattern is appropriate.

Command PatternDesign PatternsInvoker
0 likes · 13 min read
Command Pattern: Turning Operations into Objects for Undo, Redo, and Queuing
Dabaoshi
Dabaoshi
Aug 10, 2026 · Fundamentals

State Pattern Explained: Turning Conditional Logic into Flowing State Transitions

The article demonstrates how the State design pattern replaces tangled if‑else state checks with dedicated state classes, using an order lifecycle example to compare it with Strategy, explain role responsibilities, transition driving mechanisms, and guidelines for when to apply the pattern.

JavaState PatternStrategy Pattern
0 likes · 15 min read
State Pattern Explained: Turning Conditional Logic into Flowing State Transitions
Dabaoshi
Dabaoshi
Aug 10, 2026 · Fundamentals

Chain of Responsibility Pattern: Build Scalable, Extensible Validation Chains

The article explains the Chain of Responsibility design pattern, showing how to replace tangled nested if‑checks in order‑validation logic with a series of independent handler objects linked together, and demonstrates its implementation, variations, real‑world uses in filters, interceptors, and guidelines for when the pattern is appropriate.

Chain of ResponsibilityDesign PatternJava
0 likes · 15 min read
Chain of Responsibility Pattern: Build Scalable, Extensible Validation Chains
Dabaoshi
Dabaoshi
Aug 9, 2026 · Fundamentals

Observer Pattern: Decoupling Order Payment Success Actions via Publish‑Subscribe

The article explains the Observer pattern by first showing the problems of hard‑coding post‑payment actions, then detailing how defining a subject, observer interface, and concrete observers decouples the system, discusses push vs pull notification models, and illustrates real‑world uses in Spring events, GUI listeners, and message queues.

JavaObserver PatternPublish‑Subscribe
0 likes · 14 min read
Observer Pattern: Decoupling Order Payment Success Actions via Publish‑Subscribe
Dabaoshi
Dabaoshi
Aug 9, 2026 · Fundamentals

Template Method Pattern: Fix the Skeleton, Vary the Steps

The article explains the Template Method design pattern, showing how to lock a fixed process skeleton in a parent class while delegating variable steps to subclasses, contrasting it with the Strategy pattern and illustrating its use in real‑world frameworks.

Design PatternFinalHook Method
0 likes · 14 min read
Template Method Pattern: Fix the Skeleton, Vary the Steps
Dabaoshi
Dabaoshi
Aug 8, 2026 · Fundamentals

Understanding JVM Class Loading: Mechanisms, Delegation, and Custom ClassLoaders

This article walks through the full lifecycle of a Java class—from loading, verification, preparation, and resolution to initialization, usage, and unloading—explains active versus passive references, the parent‑delegation model, JDK 8‑to‑17 module‑system changes, and shows how to write a custom ClassLoader for class isolation.

Class LoadingClassLoaderCustom ClassLoader
0 likes · 26 min read
Understanding JVM Class Loading: Mechanisms, Delegation, and Custom ClassLoaders
Dabaoshi
Dabaoshi
Aug 8, 2026 · Fundamentals

Strategy Pattern: Replacing Conditional Branches with Pluggable Algorithms

The article explains how the Strategy design pattern solves the maintenance nightmare of tangled if‑else or switch statements by extracting each algorithm into its own strategy class, detailing the roles, selection mechanisms, Java examples, and when the pattern is appropriate.

ComparatorDependency InjectionDesign Patterns
0 likes · 14 min read
Strategy Pattern: Replacing Conditional Branches with Pluggable Algorithms