In addition, We can redefine the retry strategy using
retries(0..Integer.MAX_VALUE, default is 0) combined retry interval(1s..Ns,
default is 1s)

Never retry, retries=0
Retry N, retries=N (default duration is N * 1s)
Retry until succeed(Really? Maybe we just want to try within a certain time
limit), E.g. retries=3600 and retryInterval=1s (which means retry per
second within an hour)


Best regards,
Lei Zhang

On December 12, 2019 at 10:35:47 PM, Willem Jiang (willem.ji...@gmail.com)
wrote:

Maybe we can consider to disable the forward recovering with boolean
flag instead of setting the retries to 0.

Willem Jiang

Twitter: willemjiang
Weibo: 姜宁willem

On Thu, Dec 12, 2019 at 3:03 PM Zhang Lei <coolbee...@gmail.com> wrote:
>
> Hi, Feng Zheng
>
> Thank you for your reply.
>
> The question stems from the GitHub issue[1]
>
> I haven't paid attention to the forward recovery before. When I optimized
> the state machine compensation [2] recently, I found that I used retry
and
> timeout incorrectly in the compensation strategy. For this, I sent an
> email[3] discussing it.
>
> To distinguish between forward and reverse recovery properties, I have
> created a JIRA [4] to track it. I plan to add the properties
reverseRetries
> and reverseTimeout to @Compensable in another PR and use it in the state
> machine compensation strategy
>
> About the combination of forward and reverse compensation, I will create
a
> new JIRA to describe it, but I think this may cause some modification of
> the forward recovery test case.
>
> [ <https://github.com/apache/servicecomb-pack/pull/609>1]
> https://github.com/apache/servicecomb-pack/issues/589
> [2] https://issues.apache.org/jira/browse/SCB-1622
> [3]
>
https://lists.apache.org/thread.html/a81f042ba5cc711c0df0a1fe7144b5ed6e9f20336534ccf67d77dcf1%40%3Cdev.servicecomb.apache.org%3E
> [4] https://issues.apache.org/jira/browse/SCB-1646
>
>
> Best regards,
> Lei Zhang
>
> On December 12, 2019 at 12:32:32 PM, Zheng Feng (zh.f...@gmail.com)
wrote:
>
> So you want to introduce a new policy for recovering ?
>
> "try forward recovering at first in retries times, if it fails then
> following with the reverse to compensate." This makes sense but this
could
> add a new attribute with the @Compensable.
> I'm not sure if it could be incompatible.
>
> Anyway, try to raise a JIRA and record this idea.

Reply via email to