No handler for type [flattened] declared on field [host]"

Hello,

I'm taking some trainings on Elasticsearch, and I I receive an error if I try use flattened:

        ../bin/curl -XPUT "http://elastic.192.168.0.1.nip.io/demo-flattened/_mapping" -d '
        {
           "properties": {
              "host": {
                "type": "flattened"
              }
            }
        }'

And I receive the following error:
{"error":{"root_cause":[{"type":"mapper_parsing_exception","reason":"No handler for type [flattened] declared on field [host]"}],"type":"mapper_parsing_exception","reason":"No handler for type [flattened] declared on field [host]"},"status":400}

I have deployed Elasticsearch from Bitnami on K3s cluster and here is the information:

    curl -s -X GET http://elastic.192.168.0.1.nip.io
    {
      "name" : "elasticsearch-elasticsearch-coordinating-only-8bd745b84-p9ft7",
      "cluster_name" : "elastic",
      "cluster_uuid" : "EXqBWJuTSymJ7cmXEVnRBA",
      "version" : {
        "number" : "7.10.0",
        "build_flavor" : "oss",
        "build_type" : "tar",
        "build_hash" : "51e9d6f22758d0374a0f3f5c6e8f3a7997850f96",
        "build_date" : "2020-11-09T21:30:33.964949Z",
        "build_snapshot" : false,
        "lucene_version" : "8.7.0",
        "minimum_wire_compatibility_version" : "6.8.0",
        "minimum_index_compatibility_version" : "6.0.0-beta1"
      },
      "tagline" : "You Know, for Search"
    }

Do you have any ideas why it is failing? Do I need install additional licenses or xpack?
Thanks

flattened data type is not available in oss elasticsearch. You need to get a version with at least basic license (which is free).

1 Like

Thanks, this is what I thought... Is there any documentation , what features are available for each flavour ? I was not able to find that information...

https://www.elastic.co/subscriptions has that info.

1 Like

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