Configuring Experience Optimization with the smarttarget_conf file (deprecated in-process setup)
Edit the smarttarget_conf.xml file in the configuration location of your website to configure Elasticsearch and Experience Optimization.
Before you begin
- A Google Analytics service account is already set up and you have access to the configuration details.
- The P12 key associated with your Google Analytics service account must be in a location accessible by Experience Optimization services.
Procedure
- In the configuration location of your website, open smarttarget_conf.xml for editing.
- Find the
<SmartTarget>section. - Set the value of the
TimeZoneOffsetelement to the difference, in hours and minutes, from the Content Delivery system to the Content Manager system's local server time. For example, if the local time in the Content Manager server location is 5 and a half hours later than the local time in the Content Delivery server location, setTimeZoneOffsetto+5:30. - The
Analyticselement includes attributes that define of implementation of analytics for Experience Optimization.AnalyticsattributesDescription implementationClassThe Java class that implements the analytics provider Value is a fully qualified class name, and defaults to com.tridion.smarttarget.analytics.GoogleAnalyticsManager. This is the implementation class for Google Analytics that ships with Experience Optimization.
trackingRedirectUrlA relative URL to your website redirects folder Default:
"/redirect/"timeoutMillisecondsThe time in milliseconds to wait to retrieve the Experiment from the analytics provider before timing out Default: 5000
- In the
Analyticselement, set the value of thetrackingRedirectUrlattribute to relative URL to your website redirects folder, by default/redirect/. - (Optional) If your Experiments are timing out, configure In the
Analyticselement with a higher value. The default is 5000 milliseconds. Set the value of thetimeoutMillisecondsattribute to the time (in milliseconds) to wait to retrieve the Experiment from the analytics provider before timing out. - Specify parameters for the analytics provider you specified in the
implementationClassattribute. If you chose the default Google Analytics provider, set values for the following subelements:implementationClasssubelementsDescription ServiceAccountEmailAddressEmail address of the service account that you created in the Google Developers Console PrivatekeyPathFull path and filename of the P12 key you created AccountIdID of the Google Analytics service account TrackingIdTracking ID of the Google Analytics service account ViewIdView ID of the view you created in Google Analytics - If you use the default Google Analytics provider, in the
CustomDimensionssubsection, also specify the IDs of the custom dimensions you created in the subelements:CustomDimensionssubelementsDescription ExperimentIdExperiment ID InstanceIdInstance ID PublicationIdPublication ID PageIdPage ID RegionIdRegion ID ComponentIdComponent ID ComponentTemplateIdComponent Template ID ChosenVariantChosen Variant - In the
<DefaultValues>section, set the value of<AllowDuplicates>totrueif you want to allow Promotions that are already in the output of preceding regions on this Page to also be displayed in this page region. - Set the value of the
<Referrers>element to the file name of your referrers file, typically smarttarget.referrers.xml. - In the
<AmbientData>section, in the<Prefixes>subsection, map the URI of Claims to a unique prefix using the format<ClaimURI>prefix</ClaimURI>where:<ClaimURI>is the URI up to the last subpart of the string separated by underscores: the pattern that matches the prefix to the URI of a resource matches everything but the last term in the URI string.prefixis the prefix value used instead of the full Claim URI: when you define Trigger Types, you specify theurl-paramattribute, which consists of the Claim URI prefix and the last subpart of the URI string.
<AmbientData> <Prefixes> <taf_claim_audiencemanager_contact>am</taf_claim_audiencemanager_contact> <taf_claim_audiencemanager_contact_extendeddetail>am_ex</taf_claim_audiencemanager_contact_extendeddetail> <taf_claim_ambientdata_sessioncartridge>sc</taf_claim_ambientdata_sessioncartridge> <taf_claim_ambientdata_sessioncartridge_session>sc_session</taf_claim_ambientdata_sessioncartridge_session> <taf_claim_ambientdata_sessioncartridge_useragent>sc_ua</taf_claim_ambientdata_sessioncartridge_useragent> <taf_claim_ambientdata_sessioncartridge_useragent_browser>sc_ua_browser</taf_claim_ambientdata_sessioncartridge_useragent_browser> <taf_claim_ambientdata_sessioncartridge_useragent_os>sc_ua_os</taf_claim_ambientdata_sessioncartridge_useragent_os> <taf_claim_ambientdata_sessioncartridge_authorization>sc_auth</taf_claim_ambientdata_sessioncartridge_authorization> </Prefixes> </AmbientData>- Example
- In Audience Manager, for example, where a full Claim URI for a Contact extended detail such as Age is:
taf_claim_audiencemanager_contact_extendeddetail_age-
in the Claim Store, the Claim Prefix
am_exis mapped to the generic part of the URItaf_claim_audiencemanager_contact_extendeddetailso that you just need to add the specific field to the Claim prefix, in this caseam_ex_age, to address that field.Note: Colons (:) are used to separate the subparts of Claim URIs in the Claim Store. These are replaced with underscores (_) when patterns are matched against the smarttarget_conf.xml file. - Default prefixes for Audience Manager
-
The following default prefixes are configured in the smarttarget_conf.xml file for Claim URIs inserted by the Audience Manager cartridge:
<taf_claim_audiencemanager_contact>am-
Maps to Claim URIs containing a Contact's regular details, for example
BounceStatus. <taf_claim_audiencemanager_contact_extendeddetail>am_ex-
Maps to Claim URIs containing a Contact's Extended Details, for example
name.
- Default prefixes for session data
-
The following default prefixes are configured in the smarttarget_conf.xml file for Claim URIs inserted by the Session cartridge:
<taf_claim_ambientdata_sessioncartridge>sc- Maps the generic part of Claim URIs inserted by a Session cartridge to a prefix.
<taf_claim_ambientdata_sessioncartridge_session>sc_session- Maps to a Claim URI containing the value of the session length (the maximum duration of the user session specified in minutes).
<taf_claim_ambientdata_sessioncartridge_useragent>sc_ua- Maps to the following Claim URIs.
-
- The visitor browser used when making the HTTP request.
- The visitor search engine (whether the client application making the request is a web robot).
- The visitor operating system used by the client application making the HTTP request.
<taf_claim_ambientdata_sessioncartridge_useragent_browser>sc_ua_browser- Maps to a Claim URI containing the value of the web browser that was used when making the HTTP request.
<taf_claim_ambientdata_sessioncartridge_useragent_os>sc_ua_os- Maps to a Claim URI containing the value of the operating system used by the client application making the HTTP request.
<taf_claim_ambientdata_sessioncartridge_authorization>sc_auth-
Maps to the following Claim URIs:
- Whether the user has been authenticated (they are who they claim to be).
- The authorization mechanism used for communication.
- To allow other applications to use Experience Optimization data (Promotion, Page Regions and content items), within the
<AmbientData>section, set the value of<AddSmartTargetDataToClaimStore>totrue. Doing so adds such data to the Ambient Data Framework Claim Store for other applications to retrieve. - Leave all other elements and attributes set to their default values.
- Save and close smarttarget_conf.xml.