Hi, I'm working on Find 13.0.1, CMS 11.9.1. We have Find crawling an external site and the results are included in our site search. We have an issue where the search returns too many results for certain search terms as they form part of the crawled sites navigation and footer, so they're repeated on almost every page.
One way we are trying to resolve this is via a scheduled job that will iterate each of the crawled WebContent objects and strip out all the content we don't want.
There's some good documentation here https://world.episerver.com/documentation/developer-guides/find/NET-Client-API/Indexing/ which discusses updating the indexed objects if you have the items ID, the only ID I can find is the SearchHit
Below is what I'm using in the scheduled job.
I'm retrieving crawled content using SearchClient.Instance.Search
If I try to update the indexed item I don't get an error but the index isn't modified.
ITypeUpdated updateResult = SearchClient
.Instance
.Update(hit.Id)
.Field(x => x.SearchText, "New Clean Search Text");
Alternatively if I try to delete the item so I can replace it with a new 'cleaned' indexed item I get a "Not Found" error
DeleteResult deleteResult = SearchClient
.Instance
.Delete(DocumentId.Create(hit.Id));
Adding a new cleaned index item works OK but would only be a valid option if I can get the delete working.
IndexResult indexResult = SearchClient.Instance.Index(hit.Document);
Has anyone done this before, if so, where can I find the correct ID to pass? Or am I heading down the wrong path altogether.
Thanks,
Jason