Skip to content

Commit

Permalink
Merge branch 'feat/split_coordinator_cron' of github.com:scroll-tech/…
Browse files Browse the repository at this point in the history
…scroll into feat/split_coordinator_cron
  • Loading branch information
georgehao committed Oct 19, 2023
2 parents 56385fe + aa70a82 commit ad365bf
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
2 changes: 1 addition & 1 deletion common/version/version.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"runtime/debug"
)

var tag = "v4.3.36"
var tag = "v4.3.37"

var commit = func() string {
if info, ok := debug.ReadBuildInfo(); ok {
Expand Down
11 changes: 5 additions & 6 deletions prover/client/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import (
"context"
"crypto/ecdsa"
"fmt"
"net/http"
"sync"
"time"

Expand Down Expand Up @@ -35,13 +34,13 @@ func NewCoordinatorClient(cfg *config.CoordinatorConfig, proverName string, priv
SetRetryCount(cfg.RetryCount).
SetRetryWaitTime(time.Duration(cfg.RetryWaitTimeSec) * time.Second).
SetBaseURL(cfg.BaseURL).
AddRetryCondition(func(r *resty.Response, _ error) bool {
// Check for HTTP 5xx errors, e.g., coordinator is restarting.
if r.StatusCode() >= http.StatusInternalServerError {
log.Warn("Received unexpected HTTP response. Retrying...", "status code", r.StatusCode())
AddRetryAfterErrorCondition().
AddRetryCondition(func(response *resty.Response, err error) bool {
if err != nil {
log.Warn("Encountered an error while sending the request. Retrying...", "error", err)
return true
}
return false
return response.IsError()
})

log.Info("successfully initialized prover client",
Expand Down

0 comments on commit ad365bf

Please sign in to comment.