etcdserver: trace compaction request; add return parameter 'trace' to applierV3.Compaction()

mvcc: trace compaction request; add input parameter 'trace' to KV.Compact()
This commit is contained in:
yoyinzyc
2019-10-01 17:18:26 -07:00
parent 3a3eb24c69
commit 57aa68af5a
13 changed files with 92 additions and 55 deletions

View File

@@ -23,6 +23,7 @@ import (
"go.etcd.io/etcd/lease"
"go.etcd.io/etcd/pkg/report"
"go.etcd.io/etcd/pkg/traceutil"
"github.com/spf13/cobra"
)
@@ -114,7 +115,7 @@ func mvccPutFunc(cmd *cobra.Command, args []string) {
for i := 0; i < mvccTotalRequests; i++ {
st := time.Now()
tw := s.Write()
tw := s.Write(traceutil.TODO())
for j := i; j < i+nrTxnOps; j++ {
tw.Put(keys[j], vals[j], lease.NoLease)
}