Configuring storage of comments and ratings by the Content Delivery Web services
Configure in cd_storage_conf.xml where comments, ratings user data and item statistics are stored.
Procedure
- Access the WEB-INF/classes/ subdirectory (JSP) or bin\config\ subfolder (.NET) of the location where one of your Content Delivery Web services is running and open cd_storage_conf.xml in a plain-text or XML editor.
- Edit the configuration as follows:
- In the
Storageselement, add a newStorageelement and configure it to point to the UGC database you created in Creating the UGC database using TDM. The default name suggested there wasTridion_UGC. In the
StorageBindingselement inside theStorageselement, add the following:<Bundle src="ugc_dao_bundle.xml" />In the
ItemTypeselement, add the following newItemelements:<Item typeMapping="Comment" cached="false" storageId="STORAGE_ID" /> <Item typeMapping="Rating" cached="false" storageId="STORAGE_ID" /> <Item typeMapping="UGCUser" cached="false" storageId="STORAGE_ID" /> <Item typeMapping="UGCItemStats" cached="false" storageId="STORAGE_ID" />where
STORAGE_IDis the ID of the newStorageelement you just created. Caching is initially set tofalseto keep the Web site as up-to-date as possible. Consult the SDL Tridion core documentation to learn about turning caching on and configuring caching time.
- In the
- Save and close cd_storage_conf.xml.
- Copy the cd_storage_conf.xml file you just saved, and paste it in the WEB-INF/classes/ subdirectory (JSP) or bin\config\ subfolder (.NET) of your other Content Delivery Web service, overwriting the existing cd_storage_conf.xml.