Campaign elements performance considerations
When we are designing marketing activities for the site, the performance of these activities can be affected by individual marketing campaign elements. When we are creating marketing activities, consider the options and settings available for campaign elements that can be use in marketing web and dialog activities.
Targets
Targets define which customers experience your marketing activity. Specific targets and target options can have a greater effect on resources and performance than others. When we are specifying targets for our marketing activities, consider the effect that the following targets can have on your marketing performance:
- Customer segments - The customer segment target focuses on customers who belong or do not belong to specific customer segments. The customer segment target calls the CheckUserInMemberGroup command. Most implicit customer segment conditions go to the database. When WebSphere Commerce checks for customers added by marketing activities, this command queries the database for the customer segment information. To improve performance by reducing the load on the database, the site can cache user information and explicit customer segment membership information with the WCUserDistributedMapCache DistributedMap. For more information about caching user information, see WebSphere Commerce data cache.
- Shopping Cart - Targets customers whose current shopping cart contents meet certain criteria. Selecting the Shopping Cart target requires queries to the database to retrieve information from the ORDERS and ORDERITEMS database tables. These queries are required to determine whether the shopping cart meets the specified criteria. For an e-Marketing Spot evaluation, the results of the query are cached. Consider an e-Marketing Spot that has several rules, such as:
- If cart value > 1000, then A
- If cart value > 500 and value < 1000, then B
- If cart value < 500, then C
In this example, only one database query is required. Enable the WCMarketingDistributedMapCache data cache to cache queries for shopping cart target information.
- Purchase History - Targets customers whose purchase history in your store meets certain criteria. The Purchase History target also requires queries to the database to retrieve information from the ORDERS and ORDERITEMS database tables. These queries are required to determine whether a shopper meets the specified criteria. For an e-Marketing Spot evaluation, the results are cached. If your e-Marketing Spot has several similar rules, then only one database query is required. Enable the WCMarketingDistributedMapCache data cache to cache queries for shopper information.Cache the following implementation classes:
- CustomerFilterOrderTargetTaskCmdImpl
- CustomerFilterOrderCategoryTargetTaskCmdImpl
- CustomerFilterOrderProductTargetTaskCmdImpl
- Current Page - Targets customers who are currently viewing a store page that meets certain criteria. The evaluation for determining whether a shopper meets the current page target is mostly evaluated from in memory data for catalog behavior on the current page. Selecting target options for including subcategories or viewing catalog entries in a category can require catalog hierarchy queries. If your marketing activities use this target with options that require catalog hierarchy queries, enable the WCMarketingDistributedMapCache data cache.
- Catalog Browsing Behavior - Targets customers who browsed certain parts of the store catalog. This target uses information about existing user behavior that is loaded from the database and is cached. Selecting target options for including subcategories or viewing catalog entries in a category can require catalog hierarchy queries. If your marketing activities use this target with options that require catalog hierarchy queries, enable the WCMarketingDistributedMapCache data cache.
- Social Commerce Participation - Targets customers who participated in any social commerce activity on the site. This target uses information about existing user behavior loaded from the database and is cached.
- Promotion Checker - Checks a catalog entry that a customer is viewing to determine whether the catalog entry qualifies for a promotion you specify. We can cache this result information as a part of your product JSP cache. To improve performance, use this target only on pages that cache the promotion information.
Actions
Actions define what to do, based on the previous sequence of triggers and, optionally, targets in the activity flow. When we are specifying actions for our marketing activities, consider how the following actions can affect marketing performance:
- Recommendation-based promotion actions - These actions include recommend catalog entry, recommend category, and recommend content. The content for these actions, such as catalog entries, categories, and marketing content can be cached in the DynaCache command cache.
E-Marketing Spots that use this action can return only the ID information for content, instead of loading the entire content from the database or command cache. With the ID information, the client JSP then uses data beans or web services to render the content. The JSP fragment of the content can then be cached for reuse. Returning only ID information and caching the rendered content is recommended for catalog entries and is supported for categories and marketing content as well. Consider adding the sample cachespec entries to the cachespec for the store. For more information about marketing command caching, see Command caching for marketing.
- Display Merchandising Association - This action displays one or more merchandising associations. To display the merchandising associations, the server must retrieve information from the ORDERS and ORDERITEMS database tables. Depending on the options we selected for this action, queries for shopping cart, purchase history, and catalog hierarchy information can be required and cached. Consider enabling the WCMarketingDistributedMapCache data cache. For more information about caching catalog hierarchy information, see Marketing cache design considerations.
- Display Recently Viewed - This action displays a list of catalog entries or categories that a customer recently viewed. This action requires information about existing user behavior loaded from the database and is cached. For this action, the default behavior is not to persist information to the database; the recently viewed list is stored only in the user behavior cache. We can configure this action to persist the information to the database to meet the store marketing requirements. For more information about storing recently viewed information to the database, see Data recording: Improving runtime performance.
- Display Top Browsed - This action displays a list of the top-browsed catalog entries for a category you specify. If your action requires catalog browsing behavior information, WebSphere Commerce can require querying the database for catalog hierarchy information to display the list. Consider caching the e-Marketing Spot JSP that displays the top browsed results and enabling the WCMarketingDistributedMapCache data cache.
- Display Promotional Price - This action calculates and displays the discounted price of a catalog entry that a customer is viewing, based on one or more promotions you specify. We can cache the results of the calculation for this action in the product JSP cache. Consider using this action only on pages where the results are JSP cached.
- Send Message - This dialog activity action sends shoppers an email or text message (SMS) that contains your marketing message. To reduce the performance impact of this action, configure your email activities to run only during non-peak hours. For more information about configuring your email activities, see Configure email activity accounts. If your marketing activities do not require the Send Immediately option to be selected, do not select this option. We can also reduce the performance impact from this action by sending emails in a batch once per day. See Improving Email activity sending performance.
- Display IBM Product Recommendations - This action displays a list of catalog entries from IBM Product Recommendations, formerly known as Coremetrics Intelligent Offer dynamic or flat file recommendations. To reduce the performance impact of displaying these recommendations, cache the IntelligentOfferDisplayPartnumber.jsp JSP page.
Triggers
Triggers define the event that causes your dialog activities to start or continue. Use triggers to wait for a customer to do something, for an event to occur, or for time to elapse. When you create triggers for our marketing activities, consider how the triggers we select can affect your marketing activity performance.
- Subscription events - These events occur when a shopper triggers a subscription event. These triggers are scheduled to run once a day at a configured time. Ensure that you specify a time for the trigger to run that does not impact the store during peak hours. For more information about configuring the schedule time.
- Customer Places Order - This type of trigger occurs when a shopper places an order with the store. These triggers are processed by a scheduled job that runs every 30 minutes. For more information about scheduling this job, see Scheduling the SendMarketingTriggers job.
Branches
A Branch element is an element that we can add to a web or dialog activity to split a single path into two or more paths. When a customer reaches the Branch element, the customer proceeds down one or more of those paths according to criteria you define. As a result, a single activity can have multiple outcomes, and we can target each outcome to a different set of customers. If your branches include an experiment that is based on existing user behavior data, the data for this experiment is loaded from the database and cached. This experiment option can affect the load on the database. Whenever a shopper places an order, queries run to retrieve information from the ORDERS and ORDERITEMS database tables.
Activity evaluation
When we are designing how your marketing activities are to be evaluated, take into account the following considerations:
- Use branches to group related business rules together. See Branches in marketing activities.
- If the site has multiple activities that are scheduled to be used by the same e-Marketing Spot, use different priorities to determine the evaluation order. For more information about setting the priorities, see web activity scheduling in Web activities.
- In the store JSP file, specify the number of objects such as catalog entries, categories, and marketing content that are to display. Your WebServiceMarketingSpotDisplay.jsp store JSP file is in the WCDE_installdir\samples\Snippets\web\Marketing\Campaigns\ directory. To set the number of objects to display, edit the value for the numberProductsToDisplay parameter. For example, If we want one catalog entry to be returned, the parameters for our WebServiceMarketingSpotDisplay.jsp store JSP file resembles the following code:
<c:import url="….WebServiceeMarketingSpotDisplay.jsp"> <c:param name="emsName" value="ShoppingCartPage" /> <c:param name="numberProductsToDisplay" value="1" /></c:import>
Related concepts
Activity building blocks: triggers, targets, and actions
Triggers in dialog activities
Targets in marketing activities
Actions in marketing activities
Related tasks
Use the branch element in web and dialog activities
Activating or deactivating an activity