You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dubbo.apache.org by GitBox <gi...@apache.org> on 2021/07/22 03:15:54 UTC

[GitHub] [dubbo] Likenttt opened a new issue #8333: 是否有注解可以配置一个service中单个方法的retry次数.?

Likenttt opened a new issue #8333:
URL: https://github.com/apache/dubbo/issues/8333


   是否有注解可以配置一个service中单个方法的retry次数(默认为2).我注意到有两个solution,
   - 通过xml方式, 但是现在的dubbo已经大量使用注解了, 使用xml有开历史倒车的味道; 
   - 通过 `@Service`注解里面的parameter参数, 但是我浏览了一些issue,说是一个比较hack的做法,并不推荐. 
   所以是否有其他更优雅的途径?


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

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] caichy commented on issue #8333: 是否有注解可以配置一个service中单个方法的retry次数.?

Posted by GitBox <gi...@apache.org>.
caichy commented on issue #8333:
URL: https://github.com/apache/dubbo/issues/8333#issuecomment-887394494


   `@DubboService(methods = {
       @Method(name = "getById", timeout = 3000, retries = 1)})`


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

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] Likenttt commented on issue #8333: 是否有注解可以配置一个service中单个方法的retry次数.?

Posted by GitBox <gi...@apache.org>.
Likenttt commented on issue #8333:
URL: https://github.com/apache/dubbo/issues/8333#issuecomment-888110751


   > `@DubboService(methods = { @Method(name = "getById", timeout = 3000, retries = 1)})`
   
   方法很好, 可是我们还没用上dubbo 3.0. 感谢.


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

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] AlbumenJ commented on issue #8333: 是否有注解可以配置一个service中单个方法的retry次数.?

Posted by GitBox <gi...@apache.org>.
AlbumenJ commented on issue #8333:
URL: https://github.com/apache/dubbo/issues/8333#issuecomment-885373228


   可以通过配置 
   ```java
       /**
        * methods support
        *
        * @return
        */
       Method[] methods() default {};
   ```


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

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] Likenttt closed issue #8333: 是否有注解可以配置一个service中单个方法的retry次数.?

Posted by GitBox <gi...@apache.org>.
Likenttt closed issue #8333:
URL: https://github.com/apache/dubbo/issues/8333


   


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

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] Likenttt commented on issue #8333: 是否有注解可以配置一个service中单个方法的retry次数.?

Posted by GitBox <gi...@apache.org>.
Likenttt commented on issue #8333:
URL: https://github.com/apache/dubbo/issues/8333#issuecomment-887279444


   > 可以通过配置
   > 
   > ```java
   >     /**
   >      * methods support
   >      *
   >      * @return
   >      */
   >     Method[] methods() default {};
   > ```
   
   当前我使用的版本是2.7,没有这个参数 :(


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

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org