aboutsummaryrefslogtreecommitdiff
path: root/tx.go
diff options
context:
space:
mode:
authorMatt Joiner <anacrolix@gmail.com>2019-11-05 11:47:44 +1100
committerMatt Joiner <anacrolix@gmail.com>2019-11-05 11:47:44 +1100
commit1d470e07f4c8f5609eb47ac0bfd675a22872a3d4 (patch)
treeb41cc7dde356edd839d13278600953d8490f42e7 /tx.go
parentUpdate go.mod (diff)
downloadstm-1d470e07f4c8f5609eb47ac0bfd675a22872a3d4.tar.gz
stm-1d470e07f4c8f5609eb47ac0bfd675a22872a3d4.tar.xz
Add expvars
Diffstat (limited to 'tx.go')
-rw-r--r--tx.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/tx.go b/tx.go
index 45af14d..beb4cbb 100644
--- a/tx.go
+++ b/tx.go
@@ -47,6 +47,7 @@ func (tx *Tx) wait() {
}
tx.mu.Lock()
for tx.verify() {
+ expvars.Add("waits", 1)
tx.cond.Wait()
}
tx.mu.Unlock()