2

Can someone elaborate on the reason why types are deprecated while creating index in elastic search version 7.

I went through the doc link https://www.elastic.co/guide/en/elasticsearch/reference/current/removal-of-types.html mentioned by elastic search but still not able to get why is it.

I think types were helpful in searching faster through documents as similar documents are grouped together.

Aditya
  • 950
  • 8
  • 37

1 Answers1

0

what you are suggesting there, "searching faster through documents as similar documents are grouped together", is no different from using a field called filter_field and using that (which that link talks about)

however, types as they were implemented, were a bit more than just a data filtering field. and the implementation approach caused a number of issues with the way that users interacted with Elasticsearch, and the flexibility of Elasticsearch as it scales

this section goes into those technical details, and if that's not clear then it'd be great to understand why as we can make changes to it :)

warkolm
  • 1,933
  • 1
  • 4
  • 12
  • The example that they have mentioned wherein user_name field is present in both user and tweet type points that if user_name is given different data type such as text or keyword, then when deleting that field can lead to ambiguity. Is the understanding correct ? – Aditya Sep 29 '21 at 08:14
  • yep. it meant the `user_name` could be mapped as an `integer` under the `user` type and also a `keyword` under the `tweet` type. with both fields being in the same index! which is not ideal at all – warkolm Sep 29 '21 at 22:11