go - 字符过多的 Prometheus 时间戳
问题描述
我在这里使用 go 远程编写器:https ://github.com/prometheus/prometheus/blob/master/documentation/examples/remote_storage/example_write_adapter/server.go
这条线
fmt.Printf(" %f %d\n", s.Value, s.Timestamp)
打印这个时间戳 1526415583412 并且它的日期是 9/3/50340 这是不可能的。但是如果删除三个字符,它可以工作 1526415583
解决方案
Prometheus 时间戳以毫秒为单位。
推荐阅读
- django - 当我尝试在本地服务器的 admin/message/post/add/ 中保存某些内容时,我得到“没有这样的表:main.auth_user__old”
- dfa - 两种简单语言的 DFA,然后是这两种语言的产品构造
- sql - 在我的 SQL 查询中使用 Power BI 中的时间选择器作为参数
- arrays - AWK 在一个文件中的记录中搜索另一个文件中的条目
- c# - 如何在 C# 中获取 System.Numerics.Vector 的元素?
- javascript - 使用 Javascript 更改 wordpress 简码
- security - Keycloak 是否允许通过 Web 界面获取 id 令牌
- javascript - id 值作为变量 vs document.getElementById
- c# - 具有非多态子类和抽象的多态基类
- javascript - 使用 jQuery 创建一个多层次的 div 元素结构