【问题标题】:Kibana date filter is inactive for the index created by enrich processorKibana 日期过滤器对丰富处理器创建的索引无效
【发布时间】:2020-08-21 13:03:09
【问题描述】:

我通过合并 2 个索引创建了新索引。这是使用丰富的处理器完成的。以下堆栈帖子Elasticsearch merge multiple indexes based on common field

这个索引有合并的数据。但是在 Kibana 可视化上使用这些数据时,它不允许应用日期过滤器。日期过滤器总是炫耀。

这可能有什么问题?为方便起见,将步骤复制如下。

PUT /_enrich/policy/user-policy { “匹配”: { “索引”:“db-poc-user”, "match_field": "nic", “丰富字段”:[“fname”,“lname”] } }

    POST /_enrich/policy/user-policy/_execute

    PUT /_ingest/pipeline/user_lookup
    {
      "description" : "Enriching user details with tracks",
      "processors" : [
        {
          "enrich" : {
            "policy_name": "user-policy",
            "field" : "nic",
            "target_field": "tmp",
            "max_matches": "1"
          }
        },
        {
          "script": {
            "if": "ctx.tmp != null",
            "source": "ctx.putAll(ctx.tmp); ctx.remove('tmp');"
          }
        },
        {
          "remove": {
            "field": ["@version", "@timestamp", "type"]
          }
        }
      ]
    }

    POST _reindex
    {
      "source": {
        "index": "db-poc-ceg"
      },
      "dest": {
        "index": "user_tracks",
        "pipeline": "user_lookup"
      }
    }

【问题讨论】:

    标签: elasticsearch kibana


    【解决方案1】:

    您删除了管道中的@timestamp。 默认情况下,它是 kibana 用来映射上下文日期范围的字段。 你可以

    1. 从管道的删除处理器中删除 @timestamp
    2. 在您的 kibana 索引模式中选择另一个日期字段作为默认日期

    你应该可以再次使用正常的行为

    【讨论】:

      猜你喜欢
      • 2015-11-30
      • 1970-01-01
      • 1970-01-01
      • 2011-05-31
      • 2012-03-29
      • 1970-01-01
      • 1970-01-01
      • 2011-12-20
      • 2015-02-19
      相关资源
      最近更新 更多