Home > Software engineering >  Do I need to send data to Elasticsearch that I don't need for answering search requests?
Do I need to send data to Elasticsearch that I don't need for answering search requests?

Time:11-30

Suppose I have a client with name, email, company attributes and I only need to search the name and email attributes.

Do I still need to send company attribute to elasticsearch and set index to false? or just send the required attributes only?

CodePudding user response:

typically you would just index the entire document here. unless you have a massive data set (ie TBs), then the amount of savings you have would be minimal

and, from experience, there's a likely chance that someone will come along and ask to now search the company field, which means you will need to reindex everything to allow that

that said, yes you can definitely take that approach

  • Related