elasticsearch elasticsearch/kibana错误的纪元日期索引
elastichsearch或kibana从历元索引中选错了日期elasticsearch elasticsearch/kibana错误的纪元日期索引,elasticsearch,kibana,elasticsearch,Kibana,elastichsearch或kibana从历元索引中选错了日期 the date value is: 1495956650 (human date: GMT: Sunday, May 28, 2017 7:30:50 AM) 但是。。。 使用以下映射将此记录索引到elasticsearch时: PUT test { "mappings": { "doc": { "properties": { "date": {
the date value is: 1495956650 (human date: GMT: Sunday, May 28, 2017 7:30:50 AM)
但是。。。
使用以下映射将此记录索引到elasticsearch时:
PUT test
{
"mappings": {
"doc": {
"properties": {
"date": {
"properties": {
"value": {
"type": "date"
}
}
}
}
}
}
}
何时发布此数据:
POST test/doc
{"date": {
"value": "1495956650"
}
}
我在kibana看到这个日期后的索引模式,那是错误的
date.value:January 18th 1970, 11:02:36.650
我的elasticsearch和kibana版本都是6.2.3
我的系统时间正在更新。看起来elasticsearch“猜测”了
epoch\u millis
而不是epoch\u second
您需要调整映射,如下所示:
PUT test
{
"mappings": {
"doc": {
"properties": {
"date": {
"properties": {
"value": {
"type": "date",
"format": "epoch_second"
}
}
}
}
}
}
}
有关elasticsearch日期格式的更多信息