最近项目启动遇到一个错误

Caused by: java.lang.IllegalArgumentException: warning no match for this type name: com.xxx.xxx.service [Xlint:invalidAbsoluteTypeName]

原因是切面表达式错误

原始表达式为:

@Around("execution(* com.xxx.xxx.service.*(..))")

修改为

 @Around("execution(* com.xxx.xxx.service..*.*(..))")

不过还有一个诡异的情况令人不解。

就是同样的代码(使用上面的切面表达式),有的同事执行不报错,而有的报错。目前怀疑是IDEA版本问题。

更多内容请参考spring 官方文档

https://docs.spring.io/spring/docs/4.3.15.RELEASE/spring-framework-reference/html/aop.html

该部分内容的简单翻译

常见的切面表达式

1 所有公有方法的执行

execution(public * *(..))

2 所有以set开头的公有方法的执行

execution(* set*(..))

3 AccountService接口下的所有方法的执行

execution(* com.xyz.service.AccountService.*(..))

4 com.xyz.service包下的所有方法的执行

execution(* com.xyz.service.*.*(..))

5 com.xyz.service包及其子包下的所有方法的执行

execution(* com.xyz.service..*.*(..))

6 匹配com.xyz.service包下的所有类的所有方法(不含子包)

within(com.xyz.service.*)

7 com.xyz.service包和子包的所有方法

within(com.xyz.service..*)

8 匹配AccountService的代理类(不支持通配符)

this(com.xyz.service.AccountService)

warning no match for this type name:com.xxx.xxx [Xlint:invalidAbsoluteTypeName]相关推荐

  1. warning no match for this type name:xxx.xxx.xxx [Xlint:invalidAbsoluteTypeName]

    为什么80%的码农都做不了架构师?>>>    问题:warning no match for this type name:xxx.xxx.xxx [Xlint:invalidAb ...

  2. CCS5.5 中报错 Does not match the target type,not loaded 的一种情况

    出现现象:在使用CCS5.5调试TMS320DM642时,代码没有任何报错,却出现不能导入出数情况,报错信息是Does not match the target type,not loaded.用的是 ...

  3. Null return value from advice does not match primitive return type for: public abstract boolean

    今天在写Spring Data JPA的时候出现了这样一个问题 Null return value from advice does not match primitive return type f ...

  4. warning: initialization from incompatible pointer type error, forbidden解决

    android kernel报错: warning: initialization from incompatible pointer type error, forbidden warning:xx ...

  5. Spring之AOP报错:Null return value from advice does not match primitive return type for

    1.org.springframework.aop.AopInvocationException:Null return value from advice does not match primit ...

  6. spring aop Null return value from advice does not match primitive return type for总结

    Null return value from advice does not match primitive return type for这个一般都是发生在代码做了环绕后. 找到源码抛出这个异常的位 ...

  7. c语言subscripted_C语言里的 [Warning] assignment from incompatible pointer type 是什么意思啊...

    展开全部 指针类型的赋值. 不同的编译器,e68a843231313335323631343130323136353331333431356566对于不同类型间的指针变量进行赋值的编译检查是不一样的, ...

  8. [Es] Rejecting mapping update to [xxx] as the final mapping would have more than 1 type [xxx xxx]

    1.背景 写入es的时候,报错如下 Rejecting mapping update to [xxx] as the final mapping would have more than 1 type ...

  9. Type com.xxx.xxx.BuildConfig is defined multiple times:...

    版权声明:本文为延成原创文章,转载请标明出处 问题复现 >Type com.xxx.xxx.BuildConfig is defined multiple times:- 编译的时候发生. 问题 ...

最新文章

  1. Clang:LLVM的C语言家族前端
  2. python分解word文档为多个_将一个word文档按一页或多页拆分成多个文档
  3. C#怎么给新建的winform程序添加资源文件夹Resources
  4. eve可以在linux运行吗,ubuntu下为eve游戏搭载 wine环境
  5. [ios] 申请账号,发布应用
  6. 关于RocketMQ消费者消费队列的消费起始位置源码分析
  7. Unity第一人称可视化传送门制作
  8. 全国计算机研究所多少个,中国十大计算机名校是哪几所?
  9. 岁月的剪影【十二月一年之计始于此】
  10. opencv 运动检测 三帧差法
  11. 常用优化六、时间换空间和空间换时间
  12. python基础什么是函数的定义及用法
  13. Centos7 Snapper快照备份
  14. 神经网络的三种训练方法,神经网络常用训练方法
  15. matlab win7兼容,MatLab7.0和win7兼容
  16. Vue脚手架、镜像源下载及使用
  17. docker daemon调试
  18. 序列化和反序列化的概念及应用
  19. 【Hexo】nexT主题使用攻略基础——添加分类、标签及关于
  20. 最新北风网人工智能(完整版)

热门文章

  1. MyEclipse如何设置打开jsp文件时,代码和视图分成上下两块
  2. 常用的无线网络加密协议
  3. 极品飞车13,弹出“内存不能read”的解决办法
  4. 教师节感恩_Windows 10感恩节周末充斥着更新错误
  5. map使用方法 1004 HDU1113
  6. 编写一个三子棋游戏,和弱智电脑下棋
  7. 爱快递快递接口使用说明
  8. linux换网卡双网卡绑定,Linux双网卡绑定
  9. jsp设置主页和加入收藏
  10. CDH 丢失块及副本不足的块