AlexStocks commented on code in PR #744:
URL: 
https://github.com/apache/incubator-seata-go/pull/744#discussion_r1891201125


##########
pkg/saga/statemachine/engine/invoker/func_invoker.go:
##########
@@ -191,22 +191,19 @@ func (f *FuncServiceImpl) needRetry(impl 
*state.ServiceTaskStateImpl, countMap m
                return false
        }
 
-       currentInterval := f.calculateRetryInterval(retry, attempt)
+       interval := retry.IntervalSecond()
+       backoffRate := retry.BackoffRate()

Review Comment:
   line 195 以下这块代码可以精简为:
        backoffRate := retry.BackoffRate()
        curInterval := int64(interval * 1000)
        if attempt {
                curInterval = int64(interval * backoffRate * float64(attempt) * 
1000)
        }



-- 
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-unsubscr...@seata.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscr...@seata.apache.org
For additional commands, e-mail: notifications-h...@seata.apache.org

Reply via email to