Tagged articles
proxy pattern
29 articles · Page 1 of 1
This tutorial demonstrates how spring-smart-di's @AutowiredProxySPI annotation enables dynamic switching between service provider implementations by injecting a proxy that resolves the active implementation from configuration at runtime, eliminating manual bean lookups and allowing zero-restart changes via @EnvironmentProxySPI or custom config sources like databases.
@AutowiredProxySPI@EnvironmentProxySPISpring Framework
0 likes · 7 min read

This article dissects Spring Boot AOP from proxy creation (JDK vs CGLIB) and interceptor chain mechanics to practical aspects for logging, tracing, and idempotency, while exposing eight common pitfalls like self-invocation bypass, final method limits, and synchronous I/O in advice that degrade P99 latency.
AOPAspectJCGLIB
0 likes · 17 min read

This tutorial demonstrates how to use Spring-Smart-DI's @AutowiredProxySPI annotation to dynamically switch between multiple service implementations (e.g., SMS providers) at runtime by changing configuration values, without application restarts, using proxy-based injection that resolves the active implementation on each call.
@AutowiredDynamic ConfigurationJava
0 likes · 8 min read


liandkJun 25, 2026 · Fundamentals
This article introduces the Proxy design pattern, explains its core purpose of controlling access without modifying original classes, illustrates everyday analogies, provides a complete Java static‑proxy implementation with interface, real subject, proxy and test code, and summarizes common use cases and distinctions from decorators.
AOPJavaStatic Proxy
0 likes · 5 min read


java1234Mar 3, 2026 · Backend Development
This article explains MyBatis’s plugin mechanism, detailing the Interceptor interface methods, how plugins form an interceptor chain to wrap core components like Executor, and provides a step‑by‑step example of a logging plugin with code and configuration, illustrating the runtime flow and extension capabilities.
InterceptorJavaMyBatis
0 likes · 7 min read

This article explores how to apply core design patterns—Observer, Factory, Proxy, and Template Method—in Java middleware development, illustrating each pattern with practical code snippets and explaining the design rationale for building maintainable, extensible, and flexible services.
Factory PatternObserver PatternTemplate Method
0 likes · 8 min read

This article dissects the Guava library to reveal how seven classic design patterns—Builder, Proxy, Immutable, Singleton, Decorator, Adapter, and Observer—are implemented in its core classes, providing clear code examples, step‑by‑step construction processes, and practical insights for Java developers.
Builder PatternGuavaImmutable Collections
0 likes · 27 min read

This article explains the Java Proxy design pattern, its three core roles, static and dynamic implementation approaches, provides a complete code example, and outlines typical scenarios where proxies improve access control, functionality, and system decoupling.
Code ExampleJavaStatic Proxy
0 likes · 6 min read

This article examines nine design patterns employed within MyBatis—Builder, Factory, Singleton, Proxy, Decorator, Adapter, Composite, Template Method, and Iterator—detailing their roles, source code examples, and how they facilitate configuration parsing, SQL execution, and caching in the framework.
Builder PatternFactory PatternJava
0 likes · 18 min read

This article explains the Proxy design pattern, illustrates its core participants with clear Chinese idiom analogies, and provides a complete static‑proxy implementation in Java—including interface, real subject, proxy class, and client code—while also noting the distinction between static and dynamic proxies.
JavaStatic Proxydesign patterns
0 likes · 6 min read

This article explains the Proxy design pattern, covering its definition, use cases, static proxy implementation in Nacos, step‑by‑step guides for JDK dynamic proxies and Cglib dynamic proxies, and how Spring AOP leverages both approaches for method interception.
CGLIBJDKJava
0 likes · 22 min read


ByteFENov 23, 2022 · Backend Development
This article details the motivation, benefits, and technical implementation of refactoring the document parsing SDK from a monolithic design to a three‑layer architecture using Adapter, Decorator, and Proxy patterns, reducing code size by over 70% and improving extensibility for multiple document formats.
DecoratorNode.jsSDK Architecture
0 likes · 14 min read

This article explores Java's proxy patterns, detailing static proxy implementation, various dynamic proxy techniques—including JDK, Cglib, Javassist, and ByteBuddy—providing code examples, performance comparisons, and practical guidance for integrating these proxies into backend development for cleaner, more flexible code.
ByteBuddyCGLIBJDK
0 likes · 18 min read

This article explains the proxy design pattern in Java, covering static proxy, JDK dynamic proxy, and CGLIB dynamic proxy implementations with code examples, diagrams, and a comparison of their advantages, limitations, and use‑case differences.
Static Proxydesign patternsdynamic-proxy
0 likes · 9 min read

The Taobao Scan feature was refactored by applying the Responsibility‑Chain, State, and Proxy design patterns, separating view and logic layers, introducing a fluent pipeline API, modular state handling, and a global proxy, which together dramatically improved code maintainability, extensibility, testability, and reduced development risk.
State Patterndesign patternsiOS
0 likes · 13 min read

The article explains static and dynamic proxy patterns, demonstrates their Java implementations, and shows how Spring’s transaction management relies on dynamic AOP proxies—highlighting that internal calls within the same class bypass the proxy, preventing @Transactional methods from starting or rolling back transactions.
AOPJavaSpring Transaction
0 likes · 21 min read

This article explains the proxy design pattern through an engaging cartoon story, analyzes the roles of client, target, and proxy, discusses its benefits and variations, and shows practical usage examples such as ES6 Proxy, virtual image lazy‑loading, and a Golang implementation.
ES6design patternsgolang
0 likes · 4 min read

This article walks through the proxy and decorator design patterns using a coffee‑ordering example, compares their differences, explains how Spring AOP relies on proxy mechanisms, and demonstrates building a custom dynamic proxy for SMS cost tracking with JDK InvocationHandler and cglib.
AOPCGLIBDecorator Pattern
0 likes · 10 min read

This article explains the concept of proxy patterns, compares static and dynamic proxies in Java, provides detailed code examples for each, and discusses their advantages, disadvantages, and implementation steps, helping developers choose the appropriate proxy technique for their projects.
JavaReflectionStatic Proxy
0 likes · 15 min read

This article explains the proxy design pattern, demonstrates its static implementation with Java code, and shows how Nacos Client leverages a custom proxy delegate to switch between HTTP and gRPC protocols, highlighting structural roles, practical usage, and differences from the decorator pattern.
JavaNacosService Discovery
0 likes · 12 min read

The article thoroughly examines Tars’s Java RPC client, explaining its initialization, proxy generation via JDK dynamic proxies, diverse load‑balancing strategies, NIO‑based Reactor networking, and both synchronous (CountDownLatch) and asynchronous callback mechanisms, supplemented with detailed source‑code illustrations of each component.
Client DesignNIO SelectorRPC Framework
0 likes · 15 min read

This article explains the proxy design pattern in Java, demonstrates how to create static proxies, uses JDK dynamic proxies with InvocationHandler, and shows how CGLIB can generate class‑based proxies, highlighting their implementations, usage examples, and limitations.
CGLIBJDK ProxyJava
0 likes · 8 min read

This article explains the GoF Proxy pattern, illustrates static proxy implementation, and details both JDK dynamic proxy and cglib dynamic proxy techniques in Java with complete code examples and a comparison of their characteristics and usage scenarios.
JDK ProxyJavaStatic Proxy
0 likes · 8 min read

This article explains the Java proxy pattern using a real‑world analogy, compares static and dynamic proxies, details implementations with JDK Proxy and CGLIB (including code samples), and discusses how dynamic proxies support the Open‑Closed principle and are applied in Spring AOP for transaction management.
CGLIBJDK ProxyJava
0 likes · 22 min read

This article explains the Proxy design pattern, covering its purpose, static, dynamic (JDK), and CGLIB implementations in Java, provides complete code examples, discusses advantages and disadvantages, and outlines typical use cases such as lazy initialization, access control, remote services, logging, and caching.
AOPCGLIBJava
0 likes · 14 min read

This article explains the proxy design pattern, shows how to implement static proxies in Java with concrete code examples, discusses their limitations, and then demonstrates JDK dynamic proxies using InvocationHandler and Proxy classes, including generated proxy class details.
JDKJavaStatic Proxy
0 likes · 13 min read

This article explains static and dynamic proxy patterns in Java, demonstrates how to use them for recording service response times, and shows how MyBatis leverages dynamic proxies to generate mapper implementations, complete with UML diagrams and sample code.
JavaMyBatisbackend development
0 likes · 5 min read

This article explains the proxy design pattern, compares static and dynamic proxy implementations in Java, demonstrates how to use Java reflection and InvocationHandler for dynamic proxies, and shows how these techniques enable AOP features such as logging and transaction handling.
AOPJavaStatic Proxy
0 likes · 12 min read

This article explains the Proxy design pattern in Java, covering static proxy, dynamic JDK proxy, and Cglib subclass proxy with detailed code examples and discussion of their advantages, limitations, and typical usage in AOP frameworks.
AOPCGLIBStatic Proxy
0 likes · 10 min read
