-
Notifications
You must be signed in to change notification settings - Fork 38.4k
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
Suggest compilation with -parameters
when AspectJAdviceParameterNameDiscoverer
fails against ambiguity
#34609
Comments
Hi @xardael, Congratulations on opening your first issue for the Spring Framework! 👍
Just to clarify... Are you saying that your use of Or are you saying that your use of |
Hi,
I used aspectjrt v. 1.9.22.1. Edit: I just want to clarify that the exception |
I'm afraid this is a limitation of The recommended solution is to compile your code with |
-parameters
when AspectJAdviceParameterNameDiscoverer
fails against ambiguity
Thank you @jhoeller, compiled with "-parameters" solved the issue. One more questien, could it be somehow specified using Thanks. |
This should work as well. I recommend compiling with |
Hi, I had this annotation which worked with AspectJ, however stopped working after I migrated to
spring-aspects
+spring-aop
version 6.2.4:Exception is:
The problem is in
AspectJAdviceParameterNameDiscoverer.getParameterNames
- in processing parameters according to this order"Returning binding" is processed BEFORE "this target binding" so during calling
maybeBindReturningVariable()
there are two unbound arguments left, so this method throws an exception.Is this the intended behavior?
How should I use both
this
andreturning
in one@AfterReturning
annotation?Thanks.
The text was updated successfully, but these errors were encountered: