Spring AOP(一) 错误: warning no match for this type name: com.zrm.service [Xlint:invalidAbsoluteTypeName]
转载 http://www.cnblogs.com/hongwz/p/5764917.html
http://blog.csdn.net/yangxiaovip/article/details/31797475
Spring <aop:advisor />配置错误引起的
expression="execution(* com.service.*.*(..))"; // 后面两个*,表示service包下的所有类下的所有方法
<aop:config>
<!-- 切入点 -->
<aop:pointcut id="gkServicePct" expression="execution(* com.zrm.service.*(..))" />
<aop:advisor pointcut-ref="gkServicePct" advice-ref="gkTxAdvice" order="0" />
</aop:config>
出现warning no match for this type name: com.zrm.service [Xlint:invalidAbsoluteTypeName]错误
配置事务时,一定注意expression="execution(* com.zrm.service.*(..))" 应该为
expression="execution(* com.zrm.service.*.*(..))" ,这样,切点才定位到方法上了。

浙公网安备 33010602011771号