Hello guys/girls,
I am trying to upgrade from ElasticSearch 6.8 to 7.4 and need some help with my ElasticSearch index template.
My current template
{
"template" : "logstash-*",
"version" : 60001,
"settings" : {
"index.refresh_interval" : "5s",
"index.number_of_shards" : "1",
"index.number_of_replicas" : "0",
"index.mapping.total_fields.limit": "2000"
},
"mappings" : {
"_default_" : {
"dynamic_templates" : [ {
"message_field" : {
"path_match" : "message",
"match_mapping_type" : "string",
"mapping" : {
"type" : "text",
"norms" : false
}
}
}, {
"string_fields" : {
"match" : "*",
"match_mapping_type" : "string",
"mapping" : {
"type" : "text", "norms" : false,
"fields" : {
"keyword" : { "type": "keyword", "ignore_above": 256 }
}
}
}
} ],
"properties" : {
"@timestamp": { "type": "date"},
"@version": { "type": "keyword"},
"geoip" : {
"dynamic": true,
"properties" : {
"ip": { "type": "ip" },
"location" : { "type" : "geo_point" },
"latitude" : { "type" : "half_float" },
"longitude" : { "type" : "half_float" }
}
}
}
}
}
}
and I keep on getting the following error
#! Deprecation: [types removal] The parameter include_type_name should be explicitly specified in put template requests to prepare for 7.0. In 7.0 include_type_name will default to 'false', and requests are expected to omit the type name in mapping definitions.
#! Deprecation: Deprecated field [template] used, replaced by [index_patterns]
{
"acknowledged" : true
}
What do I need to do to my template for it to work in ElasticSearch 7.4?
I have read
https://www.elastic.co/guide/en/elasticsearch/reference/current/mapping.html
Along with a couple of other docs.
I know in 7.4, the removal of types is in place, but I don't know what to do to fix this problem. Feel like most of the docs are going straight over my head.