I would like to add Geopoint data to my index.
The Elasticsearch 7.6 geoip processor states I need to add the geopoint type to my index mappings.
https://www.elastic.co/guide/en/logstash/current/plugins-filters-geoip.html
This is the code for that that I've used in ES 6.5.
PUT _template/log_data/_mappings
{
"properties" : {
"@timestamp": { "type": "date"},
"@version": { "type": "keyword"},
"src addr": {"type" : "ip"},
"dest addr": {"type" : "ip"},
"log_type" : {"type" : "keyword"},
"source_geoip" : {
"dynamic": true,
"properties" : {
"location" : { "type" : "geo_point" },
"latitude" : { "type" : "half_float" },
"longitude" : { "type" : "half_float" }
}
},
"destination_geoip" : {
"dynamic": true,
"properties" : {
"location" : { "type" : "geo_point" },
"latitude" : { "type" : "half_float" },
"longitude" : { "type" : "half_float" }
}
}
}
}
And yet I get this error:
{
"error": {
"root_cause": [
{
"type": "illegal_argument_exception",
"reason": "Types cannot be provided in put mapping requests, unless the include_type_name parameter is set to true."
}
],
"type": "illegal_argument_exception",
"reason": "Types cannot be provided in put mapping requests, unless the include_type_name parameter is set to true."
},
"status": 400
}
Can someone tell me what I'm missing here?
Thanks.