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 2021/03/02 10:10:21 UTC

[GitHub] [servicecomb-java-chassis] tiger-super opened a new issue #2267: 异常信息带不带'符号问题

tiger-super opened a new issue #2267:
URL: https://github.com/apache/servicecomb-java-chassis/issues/2267


   我在consumer端和provider端都通过spi发布了这个实现
   ![image](https://user-images.githubusercontent.com/32871618/109626873-fb2a9d80-7b7b-11eb-8950-ccabc933e713.png)
   在网关处实现了HttpServerFilter输出了一下异常
   ![image](https://user-images.githubusercontent.com/32871618/109627407-8f950000-7b7c-11eb-8178-68b2a57acc89.png)
   我用1/0在consumer和provider端测试了一下
   在consumer端,网关输出的结果带'符号
   ![image](https://user-images.githubusercontent.com/32871618/109627293-70966e00-7b7c-11eb-9a83-7cc0849e1718.png)
   provider端,网关输出的结果不带'符号
   ![image](https://user-images.githubusercontent.com/32871618/109627284-6d9b7d80-7b7c-11eb-9f89-9bf08a893ef5.png)
   有没有办法都获得带'符号的异常数据
   


----------------------------------------------------------------
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 #2267: 异常信息带不带'符号问题

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






----------------------------------------------------------------
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 removed a comment on issue #2267: 异常信息带不带'符号问题

Posted by GitBox <gi...@apache.org>.
liubao68 removed a comment on issue #2267:
URL: https://github.com/apache/servicecomb-java-chassis/issues/2267#issuecomment-788770190


   SPI 试试  `public InvocationException(StatusType status, String code, String msg)`
   


----------------------------------------------------------------
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] tiger-super commented on issue #2267: 异常信息带不带'符号问题

Posted by GitBox <gi...@apache.org>.
tiger-super commented on issue #2267:
URL: https://github.com/apache/servicecomb-java-chassis/issues/2267#issuecomment-789545313


   > 看起来 consumer 的结果是 CommonExceptionData.toString 的值。
   
   看现在情况是provider抛出的异常consumer是拦截不到,只能再配置一个handler去拦截


----------------------------------------------------------------
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] tiger-super commented on issue #2267: 异常信息带不带'符号问题

Posted by GitBox <gi...@apache.org>.
tiger-super commented on issue #2267:
URL: https://github.com/apache/servicecomb-java-chassis/issues/2267#issuecomment-789495365


   > 看起来 consumer 的结果是 CommonExceptionData.toString 的值。
   
   试了一下InvocationException
   ![image](https://user-images.githubusercontent.com/32871618/109767795-0db3de00-7c33-11eb-89aa-6cd780ef1bbf.png)
   consumer和provider是一样的结果
   ![image](https://user-images.githubusercontent.com/32871618/109767845-1c9a9080-7c33-11eb-8263-ddf2bda02824.png)
   ![image](https://user-images.githubusercontent.com/32871618/109767874-24f2cb80-7c33-11eb-80db-bdda1d862cfe.png)
   


----------------------------------------------------------------
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