Tag

CGLIB

1 views collected around this technical thread.

Spring Full-Stack Practical Cases
Spring Full-Stack Practical Cases
Dec 30, 2024 · Backend Development

Which Java Bean Mapping Tool Is Fastest? Spring BeanUtils vs MapStruct vs Others

This article compares the performance of several Java bean‑mapping utilities—including Spring BeanUtils, Apache BeanUtils, Orika, Cglib BeanCopier, ModelMapper, MapStruct, and manual getter/setter code—by converting a sample Entity to a DTO 10,000 times and summarizing the results and best‑use recommendations.

Bean MappingCGLIBDTO
0 likes · 10 min read
Which Java Bean Mapping Tool Is Fastest? Spring BeanUtils vs MapStruct vs Others
Spring Full-Stack Practical Cases
Spring Full-Stack Practical Cases
Dec 9, 2024 · Backend Development

SpringBoot CGLIB Proxy Returns Null for Initialized Fields – Causes and Fixes

This article explains why a SpringBoot service field initialized with a value becomes null when accessed through a CGLIB proxy, analyzes the role of final methods and Objenesis in the proxy creation process, and provides three practical solutions to prevent the null value.

CGLIBObjenesisProxy
0 likes · 8 min read
SpringBoot CGLIB Proxy Returns Null for Initialized Fields – Causes and Fixes
Spring Full-Stack Practical Cases
Spring Full-Stack Practical Cases
Nov 28, 2024 · Backend Development

Mastering Spring AOP Proxy Mechanisms: JDK vs CGLIB and Configuration Tips

This article explains how Spring AOP creates proxies using JDK dynamic proxies or CGLIB, outlines the limitations of each approach, and shows multiple ways—including XML, YAML, and annotations—to force CGLIB usage and resolve self‑invocation issues in Spring Boot applications.

AOPCGLIBJDK Proxy
0 likes · 8 min read
Mastering Spring AOP Proxy Mechanisms: JDK vs CGLIB and Configuration Tips
Java Architect Essentials
Java Architect Essentials
Jul 1, 2024 · Backend Development

Pitfalls of Java Bean Property Copy Tools and Recommended Alternatives

This article explains why generic Java bean property copy utilities like Spring BeanUtils, Apache Commons BeanUtils, and CGLIB can cause runtime type conversion errors and performance issues, demonstrates the problems with code examples, and recommends using custom converters or IDE‑generated mapping code such as MapStruct for safe and efficient object transformation.

BeanUtilsCGLIBJava
0 likes · 8 min read
Pitfalls of Java Bean Property Copy Tools and Recommended Alternatives
Spring Full-Stack Practical Cases
Spring Full-Stack Practical Cases
Apr 30, 2024 · Backend Development

Mastering Spring AOP: XML, Annotations, and ProxyFactoryBean Deep Dive

This article explains Spring AOP fundamentals, demonstrates XML‑based and annotation‑based configurations, and provides a comprehensive guide to using ProxyFactoryBean—including its properties, proxy‑interface and proxy‑class scenarios, CGLIB considerations, and wildcard interceptor matching—complete with runnable code examples.

AOPAnnotationsCGLIB
0 likes · 9 min read
Mastering Spring AOP: XML, Annotations, and ProxyFactoryBean Deep Dive
Spring Full-Stack Practical Cases
Spring Full-Stack Practical Cases
Feb 20, 2024 · Backend Development

Mastering Spring @Lookup: Dynamic Bean Injection Explained with Code

This article explains Spring's @Lookup method injection, shows how to define the annotation, register beans, run examples, and dives into the underlying CGLIB proxy mechanism and bean creation process for dynamic bean lookup.

CGLIBJavaLookup
0 likes · 10 min read
Mastering Spring @Lookup: Dynamic Bean Injection Explained with Code
Java Architect Essentials
Java Architect Essentials
Jan 8, 2024 · Backend Development

Using MapStruct for Efficient Java Bean Copying and Mapping

This article explains why manual property copying in Java is inefficient, compares several runtime bean‑copy utilities, and demonstrates how MapStruct provides a compile‑time, type‑safe, high‑performance solution for shallow and deep object mapping, including handling of collections and ignored fields.

Bean MappingCGLIBJava
0 likes · 13 min read
Using MapStruct for Efficient Java Bean Copying and Mapping
Spring Full-Stack Practical Cases
Spring Full-Stack Practical Cases
Jan 8, 2024 · Backend Development

Why @Configuration Creates Proxies in Spring and Guarantees Singleton Beans

This article explains how Spring's @Configuration annotation triggers CGLIB proxy generation to manage @Bean methods, ensuring that internal calls return the same singleton instance, and contrasts this behavior with using @Component for configuration classes.

BeanCGLIBJava
0 likes · 8 min read
Why @Configuration Creates Proxies in Spring and Guarantees Singleton Beans
Top Architecture Tech Stack
Top Architecture Tech Stack
Nov 24, 2023 · Backend Development

Applying ASM Bytecode Manipulation in cglib and Fastjson

This article demonstrates how ASM is used to generate dynamic proxies with cglib and to create high‑performance JSON deserializers in Fastjson, providing code examples, explanation of the underlying bytecode generation, and practical tips for developers.

ASMBytecodeCGLIB
0 likes · 8 min read
Applying ASM Bytecode Manipulation in cglib and Fastjson
Architecture Digest
Architecture Digest
Aug 16, 2023 · Backend Development

Implementing Retry Mechanisms in Java: Manual Loops, Static Proxy, JDK Dynamic Proxy, CGLib, AOP, Spring Retry and Guava‑Retry

This article explains why retry mechanisms are essential for remote service calls, compares several implementation approaches—including manual loops, static and dynamic proxies, AOP, Spring Retry annotations, and Guava‑Retry—provides complete Java code examples, and discusses the advantages and drawbacks of each method.

AOPCGLIBGuava
0 likes · 15 min read
Implementing Retry Mechanisms in Java: Manual Loops, Static Proxy, JDK Dynamic Proxy, CGLib, AOP, Spring Retry and Guava‑Retry
Selected Java Interview Questions
Selected Java Interview Questions
May 19, 2023 · Backend Development

Lombok Getter/Setter Naming Issues with MyBatis and @Accessor(chain=true) Problems in EasyExcel

This article explains how Lombok's generated getter and setter method names can conflict with MyBatis property resolution and cause issues when using EasyExcel's @Accessor(chain=true) annotation, and provides detailed code examples and solutions to resolve these incompatibilities.

CGLIBEasyExcelGetterSetter
0 likes · 9 min read
Lombok Getter/Setter Naming Issues with MyBatis and @Accessor(chain=true) Problems in EasyExcel
Spring Full-Stack Practical Cases
Spring Full-Stack Practical Cases
Feb 27, 2023 · Backend Development

Mastering Spring ProxyFactoryBean: A Complete Guide to AOP Proxy Configuration

This article explains how to use Spring's ProxyFactoryBean to create AOP proxies, covering its properties, the choice between JDK and CGLIB proxies, bean configuration examples, global advisors, and practical considerations for proxying classes versus interfaces.

AOPCGLIBIoC
0 likes · 11 min read
Mastering Spring ProxyFactoryBean: A Complete Guide to AOP Proxy Configuration
Top Architect
Top Architect
Jan 11, 2023 · Backend Development

Static vs Dynamic Proxy in Java: Implementation, Execution Results, and Comparison

This article explains the differences between static and dynamic proxies in Java, provides complete code examples for static proxy, JDK native dynamic proxy, and CGLib dynamic proxy, shows their execution results, and compares their usage scenarios, especially in backend development.

CGLIBDynamic ProxyJDK
0 likes · 10 min read
Static vs Dynamic Proxy in Java: Implementation, Execution Results, and Comparison
Sanyou's Java Diary
Sanyou's Java Diary
Sep 29, 2022 · Backend Development

Java Dynamic Proxies Explained: From Static to ByteBuddy with Performance Tips

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.

ByteBuddyCGLIBDynamic Proxy
0 likes · 18 min read
Java Dynamic Proxies Explained: From Static to ByteBuddy with Performance Tips
Top Architect
Top Architect
Sep 24, 2022 · Backend Development

Understanding JDK and CGLIB Dynamic Proxies in Java

This article explains the principles, advantages, and implementation details of Java's JDK dynamic proxy and CGLIB proxy mechanisms, providing step‑by‑step code examples that demonstrate how to enhance method calls such as user registration with validation logic.

AOPCGLIBDynamic Proxy
0 likes · 11 min read
Understanding JDK and CGLIB Dynamic Proxies in Java
Sanyou's Java Diary
Sanyou's Java Diary
Jul 18, 2022 · Fundamentals

Master Java Proxy Pattern: Static, JDK Dynamic & CGLIB Implementations

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.

CGLIBDynamic ProxyJava
0 likes · 9 min read
Master Java Proxy Pattern: Static, JDK Dynamic & CGLIB Implementations
Weimob Technology Center
Weimob Technology Center
Jun 9, 2022 · Backend Development

How to Bridge Domestic and Overseas Dubbo Services with Generic HTTP Proxies

This article presents a one‑stop solution that uses dynamic proxies, Spring extensions, and Dubbo generic invocation to let overseas applications call domestic Dubbo services via HTTP without refactoring existing callers, reducing workload and eliminating previous drawbacks.

Backend IntegrationCGLIBDubbo
0 likes · 10 min read
How to Bridge Domestic and Overseas Dubbo Services with Generic HTTP Proxies
Top Architect
Top Architect
May 24, 2022 · Backend Development

SpringBoot Super Scheduled: Dynamic Management and Enhancement of @Scheduled Tasks

This article introduces the SpringBoot‑Super‑Scheduled starter, explains how it dynamically manages native @Scheduled tasks without code changes, shows quick integration steps, and details the underlying implementation—including configuration management, post‑processor interception, dynamic proxy chaining, and runtime task control—complete with code examples.

AOPCGLIBJava
0 likes · 14 min read
SpringBoot Super Scheduled: Dynamic Management and Enhancement of @Scheduled Tasks
Architecture Digest
Architecture Digest
Mar 16, 2022 · Backend Development

Spring Boot Super Scheduled: Dynamic Management and Enhancement of @Scheduled Tasks

This article introduces a Spring Boot starter that enhances native @Scheduled tasks with dynamic management capabilities, explains how to integrate the dependency, and details the underlying implementation using post‑processors, application runners, custom managers, and CGLIB‑based proxy chains to modify scheduling parameters at runtime.

AOPCGLIBJava
0 likes · 14 min read
Spring Boot Super Scheduled: Dynamic Management and Enhancement of @Scheduled Tasks
Top Architect
Top Architect
Dec 11, 2021 · Backend Development

Proxy vs. Decorator Patterns and DIY Spring AOP Implementation in Java

This article explains the proxy and decorator design patterns using a coffee analogy, provides complete Java code examples for static and dynamic proxies, discusses their differences, and shows how to implement a Spring‑like AOP mechanism with JDK InvocationHandler and cglib, while also warning about their limitations.

AOPCGLIBDynamic Proxy
0 likes · 11 min read
Proxy vs. Decorator Patterns and DIY Spring AOP Implementation in Java