You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Use @EnableTransactionManagement(proxyTargetClass = true) #5423
I don't think that's the only one that's involved here. @EnableCaching is in the same camps (and probably others). Do we really want to do that switch unconditionally? Maybe we should improve the error message instead?
@olivergierke Looks like SPR-14322 isn't going to be fixed in 4.x. I'm still tempted to leave proxyTargetClass as the new default. Do you think we need to reconsider that decision?
I have a web project that uses Spring and needed to make a batch module for it so I decided to go with Spring Boot and reused my services module from the bigger project. The services module has a ton of final methods and does not go well with cglib and it took me 2 days to understand and fix why cglib proxies where being used despite the fact that all services implemented interfaces.
I also tried changing spring.aop.proxy-target-class in properties but it was ignored (#8434).
It seems to me that changing the default was a bad call. It breaks a well known behavior of Spring.
Activity
snicoll commentedon Mar 16, 2016
I don't think that's the only one that's involved here.
@EnableCachingis in the same camps (and probably others). Do we really want to do that switch unconditionally? Maybe we should improve the error message instead?philwebb commentedon Mar 29, 2016
Switching it on by default shouldn't have any side-effects, especially since cglib is repackaged as part of Spring anyway.
odrotbohm commentedon May 31, 2016
Unfortunately it has :(. See SPR-14322 for details.
philwebb commentedon Jun 7, 2016
@olivergierke Looks like SPR-14322 isn't going to be fixed in 4.x. I'm still tempted to leave
proxyTargetClassas the new default. Do you think we need to reconsider that decision?vinisxs commentedon Mar 29, 2017
I have a web project that uses Spring and needed to make a batch module for it so I decided to go with Spring Boot and reused my services module from the bigger project. The services module has a ton of final methods and does not go well with cglib and it took me 2 days to understand and fix why cglib proxies where being used despite the fact that all services implemented interfaces.
I also tried changing spring.aop.proxy-target-class in properties but it was ignored (#8434).
It seems to me that changing the default was a bad call. It breaks a well known behavior of Spring.