Skip to content

Commit

Permalink
fix: add rate limit
Browse files Browse the repository at this point in the history
  • Loading branch information
NguyenHuy1812 committed May 7, 2024
1 parent eb43fb7 commit a377e35
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/service/binance/adapter/adapter.go
Original file line number Diff line number Diff line change
Expand Up @@ -367,7 +367,7 @@ func GetSpotTransaction(apiKey, apiSecret, symbol, startTime, endTime string) (t
}
if req.Header.Get("X-Mbx-Used-Weight-1m") != "" {
usedWeight1M, err := strconv.Atoi(req.Header.Get("X-Mbx-Used-Weight-1m"))
if err != nil || usedWeight1M > 6000 {
if err != nil || usedWeight1M > 5000 {
fmt.Printf("err: %+v, %d", err, usedWeight1M)
time.Sleep(1 * time.Minute)
}
Expand Down

0 comments on commit a377e35

Please sign in to comment.