Do search templates improve performance?

Coming from a relational background I know that using precompiled queries can also help boosting database query performance.

To my understanding search templates are the the equivalent to precompiled queries.

Though all I read about search template it is about organizing the queries better and separate them from code. Nothign about performance.

So won't search templates impact performance positivly? In the end it reduce the traffic that has to be sent around and I guess it avoids a lot of parsing (well maybe except if it does simple string-replace operations on server-side).

We are trying to optimize overal throughput on an ES cluster where the indices are pretty good (so we don't have slow individual queries). Of course we are also looking on shards etc..

So are search templates worth having a look in this context?

No. It's IMO "just" a way to send less data when you have a very big query to send.
Using a search template will require less data on the network. It won't change the response time (took field in the response).

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