Home | 2.6.6 Dependency ID overview <dependency-id> | 2.6.8 Command-based invalidation


2.6.7 Invalidation rules overview <invalidation>

Invalidation rules inform DynaCache when and how to remove objects from the cache. They are defined in exactly the same manner as dependency IDs and use the <dependency-id> definitions to work out which objects to evict.

Sample ConsumerDirect application.

<cache-entry> 
<class>command</class> 
<sharing-policy>not-shared</sharing-policy> 
<name>com.ibm.commerce.catalogmanagement.commands.AddCatalogDescCmdImpl</name> 
<name>com.ibm.commerce.catalogmanagement.commands.UpdateCatalogDescCmdImpl</name> 
    <!-- StoreCatalogDisplay Invalidation --> 
    <!-- ******************************** --> 
    <invalidation>StoreCatalogDisplay:storeId 
      <component id="getStoreId" type="method"> 
        <required>true</required> 
      </component> 
    </invalidation> 
    <!-- ********************************* --> 
    <!-- TopCategoriesDisplay Invalidation --> 
    <!-- ********************************* --> 
    <invalidation>TopCategoriesDisplay:storeId:catalogId 
      <component  id="getStoreId" type="method"> 
        <required>true</required> 
      </component> 
      <component  id="getCatalogId" type="method"> 
        <required>true</required> 
      </component> 
    </invalidation> 
    <!-- ********************************* --> 
    <!-- CategoryDisplay Invalidation      --> 
    <!-- ********************************* --> 
    <invalidation>CategoryDisplay:storeId:catalogId 
      <component  id="getStoreId" type="method"> 
        <required>true</required> 
      </component> 
      <component  id="getCatalogId" type="method"> 
        <required>true</required> 
      </component> 
    </invalidation> 
...

+

Search Tips   |   Advanced Search