diff options
author | John Cai <jcai@gitlab.com> | 2020-02-11 05:04:29 +0300 |
---|---|---|
committer | John Cai <jcai@gitlab.com> | 2020-02-11 05:05:57 +0300 |
commit | d745a8e6ec9c1800487bdf046c501d070d5c3fb3 (patch) | |
tree | 465766719168e5324e314ad4c1a3952330df723c /internal/praefect/replicator.go | |
parent | 4c854bf270703de52af43c551d85bc30afeb869e (diff) |
calculate praefect replication latency using seconds with float64
Diffstat (limited to 'internal/praefect/replicator.go')
-rw-r--r-- | internal/praefect/replicator.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/internal/praefect/replicator.go b/internal/praefect/replicator.go index 3d71e22fa..2f3a48ea3 100644 --- a/internal/praefect/replicator.go +++ b/internal/praefect/replicator.go @@ -330,7 +330,7 @@ func (r ReplMgr) processReplJob(ctx context.Context, job datastore.ReplJob) { } replDuration := time.Since(replStart) - r.replLatencyMetric.Observe(float64(replDuration / time.Millisecond)) + r.replLatencyMetric.Observe(float64(replDuration) / float64(time.Second)) if err := r.datastore.UpdateReplJob(job.ID, datastore.JobStateComplete); err != nil { l.WithError(err).Error("error when updating replication job status to complete") |