Skip to content

Commit

Permalink
prometheus: use millisecond precision timestamp
Browse files Browse the repository at this point in the history
  • Loading branch information
n8maninger committed Jan 18, 2024
1 parent 5a024a7 commit a199122
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/prometheus/encoder.go
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ func (m *Metric) encode(sb *strings.Builder) error {
// write optional timestamp
if !m.Timestamp.IsZero() {
sb.WriteString(" ")
sb.WriteString(strconv.FormatInt(m.Timestamp.Unix(), 10))
sb.WriteString(strconv.FormatInt(m.Timestamp.UnixMilli(), 10))
}
return nil
}
Expand Down

0 comments on commit a199122

Please sign in to comment.