fix(rollup): only enable chain-monitor in rollup-relayer (#1569)

Co-authored-by: colinlyguo <colinlyguo@users.noreply.github.com>
This commit is contained in:
colin
2024-12-06 13:15:22 +07:00
committed by GitHub
parent 968a396b5e
commit 06beb5dca3
2 changed files with 2 additions and 2 deletions

View File

@@ -5,7 +5,7 @@ import (
"runtime/debug"
)
var tag = "v4.4.80"
var tag = "v4.4.81"
var commit = func() string {
if info, ok := debug.ReadBuildInfo(); ok {

View File

@@ -154,7 +154,7 @@ func NewLayer2Relayer(ctx context.Context, l2Client *ethclient.Client, db *gorm.
}
// chain_monitor client
if cfg.ChainMonitor.Enabled {
if serviceType == ServiceTypeL2RollupRelayer && cfg.ChainMonitor.Enabled {
layer2Relayer.chainMonitorClient = resty.New()
layer2Relayer.chainMonitorClient.SetRetryCount(cfg.ChainMonitor.TryTimes)
layer2Relayer.chainMonitorClient.SetTimeout(time.Duration(cfg.ChainMonitor.TimeOut) * time.Second)