-
Notifications
You must be signed in to change notification settings - Fork 38.7k
Closed
Labels
in: coreIssues in core modules (aop, beans, core, context, expression)Issues in core modules (aop, beans, core, context, expression)type: bugA general bugA general bug
Milestone
Description
Christopher Sahnwaldt opened SPR-2234 and commented
The proxy created by Cglib2AopProxy handles calls to equals() with an EqualsInterceptor, but calls to hashCode() are handled by the advisors. Shouldn't there also be a HashCodeInterceptor that handles calls to hashCode()? Otherwise, two proxies for which equals() returns true may have different hash codes.
JdkDynamicAopProxy is different - it intercepts equals() and handles it itself (just like Cglib2AopProxy), but it also intercepts hashCode() and handles it itself.
I only browsed the code, though. Maybe I missed something and Cglib2AopProxy is correct.
Affects: 2.0 RC1
Metadata
Metadata
Assignees
Labels
in: coreIssues in core modules (aop, beans, core, context, expression)Issues in core modules (aop, beans, core, context, expression)type: bugA general bugA general bug