Quantcast
Channel: Using Optimizely Platforms
Viewing all articles
Browse latest Browse all 8020

Find Indexing Events?

$
0
0

I have a block controller that leverages the Find Index to fetch data that is then passed into a view.  All of this works and the block is functioning perfectly.

I want to wrap the Find logic with `IObjectInstanceCache` so that the Find call is only done for the first load of this block.  This should help speed up TTFB of the page in general, and feels like the right thing to do.

Whenever a content author adds a new page into the CMS, the Find index will be updated accordingly after some small amount of time.  How can I reliably clear my IObjectInstanceCache (e.g., `_cache.Remove(key)`) after the Find index has been updated?  Is there an event for Indexing or Indexed similar to Saving, Publishing, Creating, etc?  Is it safe enough to tap into the Published event?  I feel like there would be a race condition between Publishing completing and Find re-indexing.

I want to avoid re-architecting the block to fetch data via Ajax, as this data is used above-the-fold and it ideally needs to be available as soon as the page loads for optimal experience.


Viewing all articles
Browse latest Browse all 8020

Trending Articles