Failed to parse mapping [_doc]: properties must be a map type

I'm trying to update the routing allocation of index templates, but with the new 7.10 release, I get strange errors.

For the other version, I just GET the index template, alter the routing key, and PUT it back to the API. Since 7.10 I get this exception:

{
  "error": {
    "root_cause": [
      {
        "type": "parse_exception",
        "reason": "properties must be a map type"
      }
    ],
    "type": "mapper_parsing_exception",
    "reason": "Failed to parse mapping [_doc]: properties must be a map type",
    "caused_by": {
      "type": "parse_exception",
      "reason": "properties must be a map type"
    }
  },
  "status": 400
}

Which is strange, because there is no _doc key anymore, and when I try to add one, I get:

{
  "error": {
    "root_cause": [
      {
        "type": "illegal_argument_exception",
        "reason": "The mapping definition cannot be nested under a type [_doc] unless include_type_name is set to true."
      }
    ],
    "type": "illegal_argument_exception",
    "reason": "The mapping definition cannot be nested under a type [_doc] unless include_type_name is set to true."
  },
  "status": 400
}

Any ideas on how to fix this?

I can't figure out why this won't work.

In older templates (and in the other beats templates) I can change this.

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