升级到Spring 4.3.14后,我突然开始收到警告:
2018-04-03 WARN [main] framework.CglibAopProxy.doValidateClass():
Unable to proxy interface-implementing method [public final void
org.springframework.test.context.junit4.AbstractJUnit4SpringContextTests
.setApplicationContext(org.springframework.context.ApplicationContext)]
because it is marked as final: Consider using interface-based JDK
proxies instead!
如果我正确解释了这一点,Spring无法创建自己的类AbstractJUnit4SpringContextTests
的代理,因为其中一个方法标记为final
。
但我该如何解决这个问题呢?