1

I have a custom indexing connector with Entities associated via AssociationNavigator method. In order for Search (of SharePoint 2013) to crawl the associated entity, we need to set either the 'DirectoryLink' property or the 'AttachmentAccessor' property in the associated entity as mentioned  here

When I set the DirectoryLink property, the search crawls both the associated entity (child entity) and the parent entity.

However, when I set the child entity to be crawled as attachment, with AttachmentAccessor property, the crawler just crawls the Parent entity and  ignores the associated entity, thus it does not get indexed. 

Is this some issue with custom connectors?  The same works fine if the connector is a .net connector.

I tested the same with Microsoft's sample by changing the DirectoryLink under the File entity to AttachmentAccessor. The files now are never crawled, and instead the crawler stops at folder level.

1

After a little more digging, I sort of figured out the problem. Say for ex, we take the Microsoft sample ( http://code.msdn.microsoft.com/office/SharePoint-2013-MyFileConne-79d2ea26#content ). Here the parent entity is the Folder and the associated child entity is the File. Folder acts as a container that contains the files, hence they have used the DirectoryLink approach to crawl the files, in the AssociatedNavigation method GetAllFiles for a particular folder. However, if I changed this property to AttachmentAccessor, in this method, the Search would never call the GetAllFiles method and would just exit the process after crawling the folders. Thus files where never indexed.

The issue seems to have been that the parent entity (Folders) itself is crawled as an association (to itself, with 'DirectoryLink' property set), where it gets all the sub folders within it, and if I try crawl the associated entity (Files) with 'AttachmentAccessor' property, it does not recognize the child entity I suppose.

After I changed the parent entity (Folders) to say either an IdEnumerator or Finder method, the associated entity can be crawled as an 'AttachmentAccessor' and this resolves my issue.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.