Logstash mutate - 添加带点的字段不起作用

Logstash mutate - add field with dot not working

根据elastic convention,我们使用点进行分组。 但是,当我尝试在 add_field 中使用点时,它停止工作。

工作:

 mutate {
   add_field => {"foo" => "baz"}
 }

不工作:

 mutate {
   add_field => {"foo.bar" => "baz"}
 }

不工作:

 mutate {
   add_field => {"[foo][bar]" => "baz"}
 }

那么如何让它与字段名称中的点一起使用?

我想我找到了解决办法。

这对我有用(出于某些无法解释的原因):

 mutate {
   add_field => { "[][foo][bar]" => "baz" }
 }