This is an automated email from the ASF dual-hosted git repository.

penghui pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pulsar.git


The following commit(s) were added to refs/heads/master by this push:
     new e9bf54a  [ISSUE 10153][Go Function] fix time unit ns -> ms (#10160)
e9bf54a is described below

commit e9bf54aa9c76281557b01439ad7e65be50cb0f3f
Author: linlinnn <linjunhuac...@163.com>
AuthorDate: Mon Apr 19 22:32:45 2021 +0800

    [ISSUE 10153][Go Function] fix time unit ns -> ms (#10160)
    
    Co-authored-by: linjunhua <lin...@jiguang.cn>
---
 pulsar-function-go/pf/stats.go | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pulsar-function-go/pf/stats.go b/pulsar-function-go/pf/stats.go
index 8159cac..5aea8b2 100644
--- a/pulsar-function-go/pf/stats.go
+++ b/pulsar-function-go/pf/stats.go
@@ -243,7 +243,7 @@ func (stat *StatWithLabelValues) processTimeEnd() {
        if stat.processStartTime != 0 {
                now := time.Now()
                duration := now.UnixNano() - stat.processStartTime
-               stat.statProcessLatencyMs.Observe(float64(duration))
+               stat.statProcessLatencyMs.Observe(float64(duration) / 1e6)
        }
 }
 

Reply via email to