You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@servicecomb.apache.org by GitBox <gi...@apache.org> on 2020/08/06 02:26:35 UTC

[GitHub] [servicecomb-java-chassis] zhujiawen12345 opened a new issue #1912: 参数校验异常多抛了个java.lang.reflect.InvocationTargetException: null

zhujiawen12345 opened a new issue #1912:
URL: https://github.com/apache/servicecomb-java-chassis/issues/1912


   异常信息:一个参数校验异常打了2个异常。
   java.lang.reflect.InvocationTargetException: null
   	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_191]
   	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_191]
   	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_191]
   	at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_191]
   	at org.apache.servicecomb.swagger.engine.SwaggerProducerOperation.doInvoke(SwaggerProducerOperation.java:188) ~[swagger-invocation-core-1.2.0.B017r2.jar!/:1.2.0.B017r2]
   	at org.apache.servicecomb.swagger.engine.SwaggerProducerOperation.syncInvoke(SwaggerProducerOperation.java:173) ~[swagger-invocation-core-1.2.0.B017r2.jar!/:1.2.0.B017r2]
   	at org.apache.servicecomb.swagger.engine.SwaggerProducerOperation.invoke(SwaggerProducerOperation.java:123) ~[swagger-invocation-core-1.2.0.B017r2.jar!/:1.2.0.B017r2]
   	at org.apache.servicecomb.core.handler.impl.ProducerOperationHandler.handle(ProducerOperationHandler.java:40) ~[java-chassis-core-1.2.0.B017r2.jar!/:1.2.0.B017r2]
   	at org.apache.servicecomb.core.Invocation.next(Invocation.java:204) ~[java-chassis-core-1.2.0.B017r2.jar!/:?]
   	at com.huawei.scas.cse.sdk.exception.ExceptionHandler.handle(ExceptionHandler.java:28) ~[classes/:?]
   	at org.apache.servicecomb.core.Invocation.next(Invocation.java:204) ~[java-chassis-core-1.2.0.B017r2.jar!/:?]
   	at org.apache.servicecomb.bizkeeper.BizkeeperCommand.lambda$construct$2(BizkeeperCommand.java:79) ~[handler-bizkeeper-1.2.0.B017r2.jar!/:1.2.0.B017r2]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:50) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:30) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:50) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:30) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.Observable.unsafeSubscribe(Observable.java:8666) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeDefer.call(OnSubscribeDefer.java:52) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeDefer.call(OnSubscribeDefer.java:36) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:50) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:30) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:50) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:30) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:50) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:30) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:50) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:30) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:50) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:30) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:50) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:30) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:50) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:30) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.Observable.unsafeSubscribe(Observable.java:8666) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeDefer.call(OnSubscribeDefer.java:52) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeDefer.call(OnSubscribeDefer.java:36) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:50) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:30) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:50) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:30) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:50) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:30) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:50) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeLift.call(OnSubscribeLift.java:30) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.Observable.unsafeSubscribe(Observable.java:8666) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeDefer.call(OnSubscribeDefer.java:52) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.internal.operators.OnSubscribeDefer.call(OnSubscribeDefer.java:36) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.Observable.subscribe(Observable.java:8759) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.Observable.subscribe(Observable.java:8726) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at rx.Observable.subscribe(Observable.java:8619) ~[rxjava-1.1.6.jar!/:1.1.6]
   	at org.apache.servicecomb.bizkeeper.BizkeeperHandler.handle(BizkeeperHandler.java:78) ~[handler-bizkeeper-1.2.0.B017r2.jar!/:1.2.0.B017r2]
   	at org.apache.servicecomb.core.Invocation.next(Invocation.java:204) ~[java-chassis-core-1.2.0.B017r2.jar!/:?]
   	at org.apache.servicecomb.qps.ProviderQpsFlowControlHandler.handle(ProviderQpsFlowControlHandler.java:38) ~[handler-flowcontrol-qps-1.2.0.B017r2.jar!/:1.2.0.B017r2]
   	at org.apache.servicecomb.core.Invocation.next(Invocation.java:204) ~[java-chassis-core-1.2.0.B017r2.jar!/:?]
   	at org.apache.servicecomb.common.rest.AbstractRestInvocation.doInvoke(AbstractRestInvocation.java:243) ~[common-rest-1.2.0.B017r2.jar!/:1.2.0.B017r2]
   	at org.apache.servicecomb.common.rest.AbstractRestInvocation.invoke(AbstractRestInvocation.java:217) ~[common-rest-1.2.0.B017r2.jar!/:1.2.0.B017r2]
   	at org.apache.servicecomb.common.rest.AbstractRestInvocation.runOnExecutor(AbstractRestInvocation.java:201) ~[common-rest-1.2.0.B017r2.jar!/:1.2.0.B017r2]
   	at org.apache.servicecomb.common.rest.AbstractRestInvocation.lambda$scheduleInvocation$0(AbstractRestInvocation.java:160) ~[common-rest-1.2.0.B017r2.jar!/:1.2.0.B017r2]
   	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) ~[?:1.8.0_191]
   	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) ~[?:1.8.0_191]
   	at java.lang.Thread.run(Thread.java:748) [?:1.8.0_191]
   Caused by: com.huawei.scas.cse.sdk.exception.InaccuracyFeedBackException: autoSecurityResult cannot be null
   2020-08-06 10:16:14.202 [pool-9-thread-1] ERROR - [DefaultExceptionToProducerResponseConverter.java:convert:35] - [17024e81-42ab-41e6-af56-3d99679be866] - invoke failed, invocation=PRODUCER rest SecurityContentAnalysisService.scas.inaccuracyFeedback
   com.huawei.scas.cse.sdk.exception.InaccuracyFeedBackException: autoSecurityResult cannot be null


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [servicecomb-java-chassis] zhujiawen12345 closed issue #1912: 参数校验异常多抛了个java.lang.reflect.InvocationTargetException: null

Posted by GitBox <gi...@apache.org>.
zhujiawen12345 closed issue #1912:
URL: https://github.com/apache/servicecomb-java-chassis/issues/1912


   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [servicecomb-java-chassis] liubao68 commented on issue #1912: 参数校验异常多抛了个java.lang.reflect.InvocationTargetException: null

Posted by GitBox <gi...@apache.org>.
liubao68 commented on issue #1912:
URL: https://github.com/apache/servicecomb-java-chassis/issues/1912#issuecomment-669779519


   接口实现的未知异常都会打印 InvocationTargetException, 被处理的异常需要抛出 InvocationException,则不会打印日志。


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [servicecomb-java-chassis] liubao68 commented on issue #1912: 参数校验异常多抛了个java.lang.reflect.InvocationTargetException: null

Posted by GitBox <gi...@apache.org>.
liubao68 commented on issue #1912:
URL: https://github.com/apache/servicecomb-java-chassis/issues/1912#issuecomment-671132681


   日志是哪个类的哪一行打印出来的? 贴的日志没包含这个信息。 异常转换应该可以解决这个问题。 


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [servicecomb-java-chassis] zhujiawen12345 commented on issue #1912: 参数校验异常多抛了个java.lang.reflect.InvocationTargetException: null

Posted by GitBox <gi...@apache.org>.
zhujiawen12345 commented on issue #1912:
URL: https://github.com/apache/servicecomb-java-chassis/issues/1912#issuecomment-670272721


   > 接口实现的未知异常都会打印 InvocationTargetException, 被处理的异常需要抛出 InvocationException,则不会打印日志。
   
   异常转换可以解决这个问题吗?或者有没有什么解决方式?


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [servicecomb-java-chassis] zhujiawen12345 commented on issue #1912: 参数校验异常多抛了个java.lang.reflect.InvocationTargetException: null

Posted by GitBox <gi...@apache.org>.
zhujiawen12345 commented on issue #1912:
URL: https://github.com/apache/servicecomb-java-chassis/issues/1912#issuecomment-671133946


   > 日志是哪个类的哪一行打印出来的? 贴的日志没包含这个信息。 异常转换应该可以解决这个问题。
   具体是参数校验的时候抛出的一个自定义的异常InaccuracyFeedBackException,InaccuracyFeedBackExceptionl继承RuntimeException 重写了 
      public Throwable fillInStackTrace() {
           return this;
       }
   抛出的异常由ExceptionHandler统一处理,具体代码我私聊你espace了


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org