Search code examples
indexingliferayliferay-6

What does the Liferay documentation mean by "without using the indexer"


In the Liferay documentation, many *LocalServiceUtil classes have search methods with the following documentation:

Returns an ordered range of all the [...] matching the parameters without using the indexer, including keyword parameters for [...].

What does the without using the indexer part of the sentence mean?

In particular, does it mean that it does not use any database indexes? Does it mean that for instance JournalArticleLocalServiceUtil.search can be expected to run much slower than the equivalent JournalArticleLocalServiceUtil.getArticles? Or is it a different meaning?

Or does this indexer refer to the indexes in the result set in the same method's documentation, maybe?


Solution

  • The indexer refers to searchengine indexers such as those using Lucene, Solr, Elastic (or similar) implementations. search and getArticles operations will query the database - if you do a keyword search your database might not use in (DB) index, because content or title are not part of an index by default. Therefore, when there is a bigger amount of articles, a keyword searchengine query might lead to a better response time.