mirror of
https://github.com/etcd-io/etcd.git
synced 2024-09-27 06:25:44 +00:00
storage, test: unlock transaction in the retry loop
This commit is contained in:
parent
a907ca5e62
commit
af2569c2d8
@ -654,11 +654,11 @@ func TestRestoreContinueUnfinishedCompaction(t *testing.T) {
|
||||
tx = s1.b.BatchTx()
|
||||
tx.Lock()
|
||||
ks, _ := tx.UnsafeRange(keyBucketName, revbytes, nil, 0)
|
||||
tx.Unlock()
|
||||
if len(ks) != 0 {
|
||||
time.Sleep(100 * time.Millisecond)
|
||||
continue
|
||||
}
|
||||
tx.Unlock()
|
||||
return
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user