Overview
See #28491 for background information.
In JDK dynamic proxies created by Spring AOP, we could potentially introduce support for automatically invoking default methods (or make it easier via a utility).
Available Java APIs
java.lang.reflect.Method.isDefault()
java.lang.reflect.InvocationHandler.invokeDefault(Object, Method, Object...)
Comment From: injae-kim
In JDK dynamic proxies created by Spring AOP, we could potentially introduce support for automatically invoking default methods (or make it easier via a utility).
We can add some class to support automatically invoking default method,
but I found that only 2 proxies (HttpServiceProxyFactory
, RSocketServiceProxyFactory
) invoke default method now 😄
So I think introducing some utility
to invoke default method is enough for now!
We can easily improve it later.
I created simple PR https://github.com/spring-projects/spring-framework/pull/32018 🙇 If my PR is not what you think, please close it or share your idea~! thank you!