java - Springboot Aop !運(yùn)算符報(bào)錯(cuò)
問題描述
@Pointcut(' ! execution(* com.tadmin.admin.Control.Login.*(..))') void my(){}
&&、||都可用就是!不可用報(bào)錯(cuò):
at com.tadmin.admin.aop.MyAspect.around(MyAspect.java:38) ~[classes/:na] at sun.reflect.GeneratedMethodAccessor27.invoke(Unknown Source) ~[na:na] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_131] at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_131] at org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethodWithGivenArgs(AbstractAspectJAdvice.java:629) ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE] at org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethod(AbstractAspectJAdvice.java:618) ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE] at org.springframework.aop.aspectj.AspectJAroundAdvice.invoke(AspectJAroundAdvice.java:70) ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE] at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE] at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:92) ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE] at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) ~[spring-aop-4.3.9.RELEASE.jar:4.3.9.RELEASE]*** java.lang.instrument ASSERTION FAILED ***: '!errorOutstanding' with message transform method call failed at JPLISAgent.c line: 844
問題解答
回答1:@Pointcut('execution(* com.tadmin.admin.Control.*.*(..)) && !execution(* com.tadmin.admin.Control.Login.*(..))')
兩個(gè)execution語句就可用了
相關(guān)文章:
1. angular.js - webpack build后的angularjs路由跳轉(zhuǎn)問題2. java - web項(xiàng)目中,用戶登陸信息存儲(chǔ)在session中好 還是cookie中好,取決于什么?3. 數(shù)組按鍵值封裝!4. mysql - 查詢字段做了索引為什么不起效,還有查詢一個(gè)月的時(shí)候數(shù)據(jù)都是全部出來的,如果分拆3次的話就沒問題,為什么呢。5. mysql 新增用戶 主機(jī)名設(shè)定 失敗6. 老師,怎么不講一次性添加多個(gè)數(shù)據(jù)7. mySql排序,序號(hào)8. 單擊登錄按鈕無反應(yīng)9. mysql 創(chuàng)建root 用戶出錯(cuò),這是什么原因?mysql 中也沒有root用戶10. mysql - navicat 經(jīng)常打開表一直在載入中 也不能關(guān)閉 著急解決
