【问题标题】:Kibana doesn't show results on tile mapKibana 不在平铺地图上显示结果
【发布时间】:2015-09-25 09:17:15
【问题描述】:

我有大约 3300 个填充了 geo_point 类型字段的文档。 当我尝试在图块地图上可视化我的文档时,kibana 说“找不到结果”。

我已经尝试将坐标设置为: - 字符串中的 geohash - [经纬度] 数组 - 具有“lat”和“lon”属性的对象 - 字符串“纬度,经度”

根据ES docs,所有这些设置geo_point的方式都是允许的。 Kibana 将此字段检测为 geo_point(字段名称附近有一个地球图标),但瓷砖地图上没有显示任何内容。

我怎么了?

我使用的是 Kibana 4.2,elasticsearch 2.0.0

【问题讨论】:

标签: elasticsearch kibana-4 geohashing


【解决方案1】:

我已经做到了。

发生这种情况是因为我的 geo_point 类型字段位于带有“type”:“nested”参数的字段内。

我已将此外部字段更改为“动态”:“真”,现在我可以可视化我的位置!

【讨论】:

  • 我可以通过从映射中删除 "type": "nested" 来拥有一个嵌套的 geo_point。不需要 "dynamic":"true"。
【解决方案2】:

通过从映射中删除“type”:“nested”,我能够拥有一个嵌套的 geo_point。不需要“动态”:“真”。我的映射如下所示:

"mappings": {
        "_default_": {
            "_all": {
                "enabled": true
            },
            "_ttl": {
                "enabled": true,
                "default": "12m"
            },
            "dynamic_templates": [{
                "string_fields": {
                    "match": "*",
                    "match_mapping_type": "string",
                    "mapping": {
                        "type": "string",
                        "index": "analyzed",
                        "omit_norms": true,
                        "fields": {
                            "raw": {
                                "type": "string",
                                "index": "not_analyzed",
                                "ignore_above": 256
                            }
                        }
                    }
                }
            }],
            "properties": {
                "@version": {
                    "type": "string",
                    "index": "not_analyzed"
                },
                "user_data": {
                    "properties": {
                        "user_geolocation": {
                            "properties": {
                                "location": {
                                    "type": "geo_point"
                                }
                            }
                        }
                    }
                }
            }
        }
    }

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2020-10-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多