Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • AbsolutelyN 89 posts 437 karma points
    Feb 27, 2020 @ 15:35
    AbsolutelyN
    0

    Rebuild custom index Umbraco 8?

    Hi

    I've built a custom index for searching items in a a custom section. It all works great and is extremely fast. However when a change is made to one of the items in the index I need the index to reflect the change.

    I can't find any reference on how to go about this in the docs. https://our.umbraco.com/documentation/reference/searching/examine/indexing/

    Anyone know of an example showing how to do this?

    Many thanks!

  • AbsolutelyN 89 posts 437 karma points
    Feb 27, 2020 @ 16:42
    AbsolutelyN
    100

    Solved. There is an example of updating index in the Umbraco source code here:

    https://github.com/umbraco/Umbraco-CMS/blob/99d2bef704b5808c688be9c30f3da1abebf87572/src/Umbraco.Web/Editors/ExamineManagementController.cs

    Rather than rebuild all you need to do is call the IndexItem method: index.IndexItem(ValueSet model);

    Hope this helps should anyone need it.

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies