November Happy Hour will be moved to Thursday December 5th.

EPiServer FTS search returning recycle bin content

Vote:
 

I'm experiencing an issue where recycling bin content is being returned in search queries. The website is built on EPiServer v7 and is a fairly simple website with straight forward content using EPiServer FTS for search. 

Further detail:

The lucene query sent to EPiServer FTS is the following:

(EPISERVER_SEARCH_DEFAULT:(broome))
AND
(
  (
    (EPISERVER_SEARCH_TYPE:("EPiServer.Core.PageData,EPiServer"))
    AND 
    (EPISERVER_SEARCH_CULTURE:(en)) 
    AND 
    (EPISERVER_SEARCH_VIRTUALPATH:(43f936c9\-9b23\-4ea3\-97b2\-61c538ad07c9|5ef8dbb4\-92c0\-4ed2\-9235\-94de3f3a9aad*))
  ) 
  OR 
  (
    (EPISERVER_SEARCH_VIRTUALPATH:(0882065f\-76c9\-47af\-8ffb\-f739c219a849*)) 
    AND 
    (EPISERVER_SEARCH_TYPE:("EPiServer.Web.Hosting.UnifiedFile,EPiServer"))
  )
) 
AND 
(
  EPISERVER_SEARCH_ACL:(G\:Everyone) 
  OR 
  EPISERVER_SEARCH_ACL:(G\:Anonymous)
)

I’ve bolded the key line to focus on. This defines the virtual path that FTS should filter the query of content to. The guid “43f936c9\-9b23\-4ea3\-97b2\-61c538ad07c9” represents the very root node of the site (id 1) and the next guid “5ef8dbb4\-92c0\-4ed2\-9235\-94de3f3a9aad” is the start page of the site – this path looks correct to me as it’s the full path to the start page and has the wildcard to allow all descendants to match. But strangely, though we get content we want, we also get items in the recycle bin.

As an example one of the offending results (in the recycle bin) has the virtual path “43f936c9-9b23-4ea3-97b2-61c538ad07c9|2f40ba47-f4fc-47ae-a244-0b909d4cf988|53ef3bd3-d9e7-4842-ad10-ee3edf7a5761|e4e4889f-ce2a-450b-acdf-bec22e45baa9” which to me shouldn’t be returned since the second item in its path doesn’t match the search filter.

I’m not sure if the index is out of sync or whether the querying has an issue. Any thoughts would be appreciated :)

#77125
Nov 11, 2013 1:21
Vote:
 

First make sure to set the startingpoint for search to StartPage of your website, as you mentioned. If you are using WebForms you could use the episerver:searchdatasource control to check if you get the same result. Are you using the built in search in EPiServer 7 or do you use the old FTS that was developed for CMS6? If you har using the old FTS tryt to download the latest search via nuget for episerver cms 7.

You could of cource clear and reindex your content but browsing this adress: http://yoursite/EPiServer/CMS/Admin/IndexContent.aspx This is a hidden gem where you can reindex your website. 

#86767
May 30, 2014 9:50
Vote:
 

Hi Eric

Really appreciate your reply! I ended up contacting EPiServer support who helped me through to a solution. Your answer would have solved it for me too - I wasn't aware of the orphaned page http://yoursite/EPiServer/CMS/Admin/IndexContent.aspx and firing off the index from there did resolve the issue :) I guess the index must have gotten out of sync - but I'm not sure why as with the amount of mucking around it should have triggured a full index through initialization but nevertheless the link you and support mentioned somehow indexed it correctly.

Thanks

Matt

#86801
Jun 02, 2014 4:44
Vote:
 

Great you find the solution. Could you please mark the post as solved? :)

#86811
Jun 02, 2014 11:05
This topic was created over six months ago and has been resolved. If you have a similar question, please create a new topic and refer to this one.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.