Uploaded image for project: 'Solr Search Provider'
  1. Solr Search Provider
  2. MGNLEESOLR-65

FacetedSolrSearchProvider should not cache search queries since Solr index might have changed

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Critical
    • 3.0
    • 2.0
    • Solr 4, crawler
    • Sprint 3 (Kromeriz)
    • 5

    Description

      I think since version 2.2 the FacetedSolrSearchProvider does some sort of (in memory) caching of the last performed search query. It does not perform a new search when the search query string is the same as the previous one.

      This of course can never work since the Solr index might very well have changed in between the two queries! We now see this issue on our servers in the following scenario:

      1. Remove all documents from the index
      2. Perform a search on search string 'test'
      3. The search correctly returns no results
      4. (re)create the Solr index. In our case by starting the crawler from the content-indexer module
      5. Perform the same search again.
      6. The search still returns no results even though there are many hits in the new Solr index..

      The solution is very simple: please remove this caching feature altogether. Unless I don't understand it I think this is a mistake. If any caching is done it should be done by the Solr server itself. That is what Solr is for.

      Checklists

        Acceptance criteria

        Attachments

          Issue Links

            Activity

              People

                mdivilek Milan Divilek
                edgar Edgar Vonk
                Michaƫl van der Mark
                Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved:

                  Checklists

                    Bug DoR
                    Task DoD

                    Time Tracking

                      Estimated:
                      Original Estimate - 3d
                      3d
                      Remaining:
                      Time Spent - 1h 32.25m Remaining Estimate - 2d 6h 27.75m
                      2d 6h 27.75m
                      Logged:
                      Time Spent - 1h 32.25m Remaining Estimate - 2d 6h 27.75m
                      1h 32.25m