首页 > 技术文章 > Caused by: java.lang.IllegalArgumentException: error Type referred to is not an annotation type: xxx

liyhbk 2020-12-10 13:24 原文

报错全称

Caused by: java.lang.IllegalArgumentException: error Type referred to is not an annotation type: xxx

疑似产生的原因

修改过注解的包名

解决方案

1)将注解改为全路径全称

@Pointcut("@annotation(Log)")   改为     @Pointcut("@annotation(com.liyh.logging.aop.Log)")

重启,继续报错:

但是,这个报错的类并不是刚才那个类呀。

因此,搞定,——这个新错误也是同样的解决办法。

推荐阅读