cancel
Showing results for 
Search instead for 
Did you mean: 

Solr DefaultFacetSearchStrategy | Query parameter is passed as empty

Former Member
0 Kudos

Hi,

I'm using Hyrbis 5.7.0.3 b2b powertools accelerator and facing solr query issue when i turn off the legacy mode in solrquery config.

Problem: In LegacyMode, things are working but when i turn off the legacy mode in solrsearchconfig, Solr uses DefaultFacetSearchStrategy in order to generate solr query and get the search results. With this, everytime i search on the page, same results are shown. When i debug the query below query was printed in the logs:

q=%3A&sort=score+desc%2CinStockFlag_boolean+desc%2Cscore+desc&start=0&rows=20&facet.field=Colour+of+product%2C+1766_en_string&facet.field=price_usd_string&facet.field=allPromotions_string_mv&facet.field=categoryPath_string_mv&facet.field=allCategories_string_mv&facet.field=availableInStores_string_mv&facet=true&facet.sort=count&facet.mincount=1&facet.limit=50&spellcheck=true&spellcheck.q=screw&spellcheck.dictionary=en&spellcheck.collate=true&fq=%28catalogId%3A%22csmProductCatalog%22+AND+catalogVersion%3A%22Online%22%29

If you look at the above query, "q" parameter is taking value as "*:*" instead of search term.

Does anyone has experienced this behaviour?

Former Member
0 Kudos

Also tried viewing the platform files, as per the converter class which generates the query, below populators are invoked in order to create a query

             <ref bean="facetSearchQueryFilterQueriesPopulator" />
             <ref bean="facetSearchQueryGroupingPopulator" />
             <ref bean="facetSearchQuerySortsPopulator" />
             <ref bean="facetSearchQueryPagingPopulator" />
             <ref bean="facetSearchQueryFacetsPopulator" />
             <ref bean="facetSearchQueryFieldsPopulator" />
             <ref bean="facetSearchQuerySpellcheckPopulator" />
             <ref bean="facetSearchQueryParamsPopulator" />
             <ref bean="facetSearchQueryCatalogVersionsPopulator" />

First ref in the list belongs to FacetSearchQueryBasicPopulator.class file which somehow is not opening up in decompiler and i believe its responsible for generating "q" parameter.

Accepted Solutions (1)

Accepted Solutions (1)

former_member537989
Contributor
0 Kudos

Why do you switch the legacyMode to false in such case - if it works for you? Have you seen the description of the mode difference: https://wiki.hybris.com/display/release5/Search+Process If you want to change mode for search in your application then you will need to check the Index type/properties configuration (fts* fields) because new search strategy doesn't use the populators for free text queries.

Answers (0)