Understanding doc_values

This does look like an issue, the syntax looks correct for disabling fielddata and enabling doc_values, but it seems to thing fielddata is enabled regardless.

I did test and since doc_values are the default for not_analyzed fields in 2.4.5, you can use:

POST _template/test
{
  "order": 0,
  "template": "test",
  "settings": {
    "number_of_shards": 1,
    "number_of_replicas": 0
  },
  "mappings": {
    "data": {
      "properties": {
        "name": {
          "type": "string",
          "index": "not_analyzed"
        }
      }
    }
  }
}

And then your example works

1 Like