How to change type of field in logstash for xml plugin

I want to change some field types from text(by default) to float for aggregation purpose from xml parsed data.
kindly find my logstash configuration below

xml {
source => "[data][cdr]"
target => "cdr"
}
mutate {
rename => { "[cdr][inbound][flaw_total]" => "cdr_inbound_flaw_total" }
convert => { "inbound_mos" => "float" }

data is getting parsed from xml plugin but mutate filter is not working.
Please help me on this

The convert mutate has no effect on Elastic mappings. You still need to ensure your data is being mapped as a float.

PUT YOUR-INDEX-NAME
{
  "mappings": {
    "properties": {
      "inbound_mos": {
        "type": "float"
      }
    }
  }
}

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.