benchmark: printSecondSample with time series
This commit is contained in:
@ -42,6 +42,7 @@ func init() {
|
||||
RootCmd.AddCommand(rangeCmd)
|
||||
rangeCmd.Flags().IntVar(&rangeTotal, "total", 10000, "Total number of range requests")
|
||||
rangeCmd.Flags().StringVar(&rangeConsistency, "consistency", "l", "Linearizable(l) or Serializable(s)")
|
||||
rangeCmd.Flags().BoolVar(&sample, "sample", false, "'true' to sample requests for every second")
|
||||
}
|
||||
|
||||
func rangeFunc(cmd *cobra.Command, args []string) {
|
||||
@ -112,7 +113,7 @@ func doRange(client v3.KV, requests <-chan v3.Op) {
|
||||
if err != nil {
|
||||
errStr = err.Error()
|
||||
}
|
||||
results <- result{errStr: errStr, duration: time.Since(st)}
|
||||
results <- result{errStr: errStr, duration: time.Since(st), happened: time.Now()}
|
||||
bar.Increment()
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user