Best way to store text in elasticsearch that does not need to be search, analyzed or aggregatable?

Viewed 578

What is better solution for storing just a text in elasticsearch 5.x for a text field no longer then 256 characters, when this field does NOT need to be:

  • searchable
  • indexed
  • analyzed
  • sortable...

Option 1) Set mapping to text with index=false

Option 2) Set mapping to keyword with index=false, doc_values=false

What is more space efficient? Or what is the difference between these two mappings whit these settings?

Thank you.

1 Answers
Related