fn: fix math error in calculating msecs in container states (#1157)

This commit is contained in:
Tolga Ceylan
2018-08-03 17:25:01 -07:00
committed by GitHub
parent 558b296e50
commit b524a94651

View File

@@ -142,7 +142,7 @@ func (c *containerState) UpdateState(ctx context.Context, newState ContainerStat
timeKey := containerTimeKeys[oldState]
if timeKey != "" {
stats.Record(ctx, containerTimeMeasures[oldState].M(int64(now.Sub(before).Round(time.Millisecond))))
stats.Record(ctx, containerTimeMeasures[oldState].M(int64(now.Sub(before)/time.Millisecond)))
}
// update new state stats