Dealing with IPs and the end of mapping types

So, I've been reading a lot about how the mapping types are "in extinction" and will be gone in 8.x, but I don't understand is how do we deal with searching related to IP types when it's gone.

Maybe there's something about this somewhere I haven't found yet?

Document types are being deprecated, not mapping types.

Did I understand this wrong, then?

Indices created in Elasticsearch 7.0.0 or later no longer accept a default mapping. Indices created in 6.x will continue to function as before in Elasticsearch 6.x. Types are deprecated in APIs in 7.0, with breaking changes to the index creation, put mapping, get mapping, put template, get template and get field mappings APIs.

I can't seem to make a template that gets accepted when using type IP

In earlier Elasticsearch versions documents could be of different types within an index. This started being deprecated in Elasticsearch 6.0. Index mappings used to specify the document type, and it is this that is now being removed.

You can see this if you compare the docs for version 6.8 with the docs for version 7.6. Note how the level after mapping no longer specifies the document type (in this case _doc).

1 Like

hm... I need to find out where I found documentation that made me try this code:

  "mappings" : {
    "_default_" : {
      "properties": {

for what I understood from you explanation, if I remove _default_ it should work, then...

[edit] oh yeah, it worked! awesome, thanks @Christian_Dahlqvist =D

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