From 44b49bec99a4f40eaf890a6aa361716e1cd10ab0 Mon Sep 17 00:00:00 2001 From: Chris Lu Date: Sun, 4 Feb 2024 12:47:07 -0800 Subject: [PATCH] less verbose --- weed/cluster/lock_client.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/weed/cluster/lock_client.go b/weed/cluster/lock_client.go index 82d6785a1..57801735c 100644 --- a/weed/cluster/lock_client.go +++ b/weed/cluster/lock_client.go @@ -111,12 +111,10 @@ func (lock *LiveLock) retryUntilLocked(lockDuration time.Duration) { func (lock *LiveLock) AttemptToLock(lockDuration time.Duration) error { errorMessage, err := lock.doLock(lockDuration) if err != nil { - glog.Warningf("lock1 %s: %v", lock.key, err) time.Sleep(time.Second) return err } if errorMessage != "" { - glog.Warningf("lock2 %s: %v", lock.key, errorMessage) time.Sleep(time.Second) return fmt.Errorf("%v", errorMessage) } @@ -167,7 +165,9 @@ func (lock *LiveLock) doLock(lockDuration time.Duration) (errorMessage string, e } if resp.LockOwner != "" { lock.owner = resp.LockOwner + // fmt.Printf("lock %s owner: %s\n", lock.key, lock.owner) } else { + // fmt.Printf("lock %s has no owner\n", lock.key) lock.owner = "" } }