The /atg/endeca/assembler/cartridge/handler/DimensionValueCacheRefresh component (of class atg.commerce.endeca.assembler.cartridge.handler.DimensionValueCacheRefreshHandler) is responsible for accessing the MDEX to populate the associated cache. If an attempt is made to access a cache that does not exist, the DimensionValueCacheTools.createEmptyCache() method is invoked to create an empty DimensionValueCache. The DimensionValueCacheRefresh component then accesses the MDEX to populate the cache. For each dimension value of the specified dimension, DimensionValueCacheRefresh creates a new DimensionValueCacheObject that stores the dimension value ID, the repository ID, the URL, and the repository IDs of the item’s ancestor items.

If a cache lookup fails to find an entry, this may be because the cache is out of date. When this happens, DimensionValueCacheRefresh attempts to refresh the cache by recreating all of the entries. However, to prevent unnecessary refreshes (such as when an entry is not found because it has not been indexed, which means a refresh will not fix the failed lookup), the cache is not refreshed if any of the following conditions exist:

Key properties of the DimensionValueCacheRefresh component include:

Populating the DimensionValueCacheObject.url Property

To populate the url property of a DimensionValueCacheObject with an appropriate link, the DimensionValueCacheTools component invokes the Assembler. These links must always begin with the /browse content path and, as such, they require the DimensionValueCacheTools component to perform an extra step. Specifically, before the invocation, the DimensionValueCacheTools component modifies the request it passes to the Assembler to add a new request attribute, DefaultActionPathProvider.ALWAYS_USE_DEFAULT_NAVIGATION_CONTENT_PATH, and sets it to true. This request attribute forces the Assembler to use the DefaultActionPathProvider component’s defaultExperienceManagerNavigationActionPath property when setting the content path for the url, instead of going through the normal DefaultActionPathProvider calculations to derive the content path. Because this property is set to /browse by default, forcing the Assembler to use it ensures that the links returned to the DimensionValueCacheTools component are correct. The DimensionValueCacheTools object subsequently removes the additional request attribute after the links are retrieved, so any other invocations of the Assembler proceed as normal.

Note: For more details on Assembler invocation and the DefaultActionPathProvider component, see the Query Integration chapter.


Copyright © 1997, 2013 Oracle and/or its affiliates. All rights reserved. Legal Notices