diff --git a/supernode/daemon/mgr/gc/gc_peer.go b/supernode/daemon/mgr/gc/gc_peer.go index 8d44725b9..e8c7c3b46 100644 --- a/supernode/daemon/mgr/gc/gc_peer.go +++ b/supernode/daemon/mgr/gc/gc_peer.go @@ -19,6 +19,7 @@ package gc import ( "context" "sync" + "time" "github.com/dragonflyoss/Dragonfly/pkg/timeutils" "github.com/dragonflyoss/Dragonfly/supernode/util" @@ -41,7 +42,7 @@ func (gcm *Manager) gcPeers(ctx context.Context) { } if peerState.ServiceDownTime == 0 || - timeutils.GetCurrentTimeMillis()-peerState.ServiceDownTime < int64(gcm.cfg.PeerGCDelay) { + timeutils.GetCurrentTimeMillis()-peerState.ServiceDownTime < int64(gcm.cfg.PeerGCDelay/time.Millisecond) { continue }