Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

What is the ProxyReplacerTransformer in the Spring plugin used for? #517

Open
wangjingf opened this issue Dec 3, 2023 · 1 comment
Open
Labels

Comments

@wangjingf
Copy link

Related classes include these:

DetachableBeanHolder
EnhancerProxyCreater
HotswapSpringInvocationHandler
ProxyReplacer
ProxyReplacerTransformer
SpringHotswapAgentProxy
What is described in #51 is to enable spring's cglib proxy class hotswap, but I have been testing and understanding the code for a whole day. Without these codes and Proxy plugin, spring's proxy class hotswap still works well.(I even downloaded version 0.1-beta4-SNAPSHOT of HA before this feature, but Spring proxy swap still works fine)

My test code is like this(SpringBoot 2.3.2.RELEASE):

@Aspect
@Component
public class AnotherAspect {
    @Pointcut("execution(public * xx.AnotherService.service(..)) ")
    public void pointCut_search() {
    }

    @Around("pointCut_search()")
    public Object around_search(ProceedingJoinPoint proceedingJoinPoint) throws Throwable {
        return proceedingJoinPoint.proceed();
    }
}

@Service
public class AnotherService {(implement or extends someting...)
    public String service() {
         //...
    }
//doing some add method, change method things...
}
@wangjingf
Copy link
Author

can anyone help me?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants