Skip to content

Commit

Permalink
完善 access token 刷新逻辑
Browse files Browse the repository at this point in the history
  • Loading branch information
rianli committed Dec 18, 2024
1 parent 0ca90cc commit 77aba12
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion token/token_source.go
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ func StartRefreshAccessToken(ctx context.Context, tokenSource oauth2.TokenSource
panic("get token failed continuously for more than ten times")
}
consecutiveFailures++
refreshMilliSec = int64(time.Second)
refreshMilliSec = 1000 // 1000ms后重试
} else {
consecutiveFailures = 0
refreshMilliSec = getRefreshMilliSec(tk.ExpiresIn)
Expand Down

0 comments on commit 77aba12

Please sign in to comment.