Administer > Dynamic caching > Improve marketing performance using caching > Enable JSP caching


Set up JSP snippet caching for best seller and top browsed lists

If you have a Web activity that uses either the Display Top Browsed action or Display Best Sellers action, you can improve performance with caching. The marketing services update best seller and top browsed lists only once a day. Take advantage of JSP caching so that the list displayed on the storefront is refreshed only once a day, after the list is updated.

To set up this type of caching, add a RankingEMarketingSpot dependency ID to the cache configuration file. The dependency ID will be issued when the marketing services call the InvalidateRankingServletCmdImpl command. This invalidate command is called once a day, after the lists have been updated. As a result, the list displayed on the store page will be refreshed.


Procedure

  1. Open the cachespec.xml cache configuration file...

    • WCDE_INSTALL/workspace/stores/WebContent/WEB-INF/

    • WC_INSTALL/Stores.war/WEB-INF/

  2. Find the <cache-entry> section for the e-Marketing Spot that displays the top browsed or best seller list.

  3. Above the </cache-entry> end tag, add the following line of code to define the dependency ID:

    <dependency-id>RankingEMarketingSpot</dependency-id>
    

  4. Add the following additional </cache-entry> below the previous entry:

    <cache-entry>   
    <class>command</class>   
    <name>com.ibm.commerce.marketing.commands.ranking.InvalidateRankingServletCmdImpl</name>   
    <invalidation>RankingEMarketingSpot</invalidation>
    </cache-entry>
    

  5. Save and close the file.


Related concepts

Action: Display Best Sellers

Action: Display Top Browsed


+

Search Tips   |   Advanced Search