To Engage or not to Engage
There are approximately 7500 types of Apples in the world; roughly 100 types of those are grown commercially, to be sold in the U.S. Due to regional and seasonal constraints those get narrowed down to a handful in our local supermarkets. Can you imagine if all the Apples sold in a supermarket were put into a single container and you had to find and pick six Royal Gala Apples amongst the hundreds or maybe thousands of Apples?
Luckily for us most supermarkets will have their Apples separated by type, organic vs non-organic and is likely located in a dedicated area for produce. If only it were that simple for websites, with the sheer volume of content available it is often a challenge for visitors to find content that would interest them. Here is where WCS (WebCenter Sites) Engage comes in.
Engage empowers the business users to target content to visitors based on their behavior or their profile configuration (what we WCS folks call Implicit or Explicit personalization). With the versatility of WCS’s data model this content could be recommended Articles, ads, products or any asset determined by the business. The diagram below provides an overview of how the components of Engage work together to provide a tailored experience:
As the site visitor consumes content WCS captures behavioral information through their click stream and profile information (typically provided through login). The Decision Engine takes this information and uses it to determine to which segments a visitor belongs. Once the visitor’s segments have been identified the Decision Engine uses the segment-to-content configuration on the Recommendation asset to determine the content to be displayed.
Engage comes packaged with WCS Sites out of the box with no additional licensing costs. When using Engage the default configuration all the data is stored and retrieved from the WCS database when performing any Engage related operation. This potentially could put additional strain on the system that could result in performance degradation on large-scale websites.
WCS does allow some tweaking of Engage to improve performance by easing the load on the WCS database. The following can be done:
- Place the Visitor Attributes in memory as opposed to querying them from the database.
- Capture History attributes in memory initially and write them to the database in batches as opposed to store them directly in the database each time.
- The WCS database is queried in intervals to calculate the sums and counts and store the result in memory instead of reading them from the database.
- Now when calculating segments the visitor attributes and the sums and counts are already in memory so only the History Attributes need to be retrieved from the WCS database.
- Code can be added to the Templates and Elements to reduce the number of dependencies logged to help with performance.
In order to enable the Memory-Centric model the following must be done:
- Add vis.useSessionVisitorConnection=true property to the Vistor.ini property file. Note this only needs to be done on Delivery Servers, as Management Servers does not support the Memory-Centric mode.
- Add custom code to Templates and Elements to retrieve Scalar attributes from the external repository.
- In order to facilitate the batch processing of the History Attributes a property file must be added to the classpath named after the configured JDBC DataSource for the WCS database and contain the following properties:
- Driver (JDBC driver class name)
- url (JDBC url for the WCS database)
- user (database username for WCS database)
- password (database password for WCS database)
for example if your DataSource is called csdata, the property should be called csdata.properties.
- A JVM argument must be added to the Application server to set the interval by which History Attributes are written from memory to the file system to be synced with the WCS database. The JVM argument is
-Dvisitor.SyncInterval=<time in seconds>
Note even with the above mentioned improvements WCS Engage is still resource intensive and care must be taken to ensure the Infrastructure supports the load and is capable of meeting the SLA (Service Level Agreement) on page load times.
Forgoing my attempt at Shakespearean word play in the title, to me it’s not a question whether one should use Engage or not; it’s more a question of how to use it. In today’s Omni-channel world more and more people are accessing content via a personalized device such as a phone, tablet or personal computer. Through these channels business’s now have direct access to their consumers and Engage is a key mechanism that can enable a business to talk with their customers and learn more to create a dialog that derives value and adds a personal touch for the visitor’s experience.