Tutorials > Content management
Tutorial: Add content managed resources to the Catalog service module
This tutorial demonstrates how to add workspace support to the Catalogs tool. This tutorial continues the Warranty scenario, and uses the schema and Management Center customizations you have performed as part of Tutorial: Adding new properties to a WebSphere Commerce service using the data service layer and Tutorial: Adding new fields in the Catalogs tool.
To make the Warranty schema customization content managed, enable workspace support for the two new tables. Using workspaces prevents the same object from being edited by users in different task groups within the same workspace. Workspaces in the Management Center use BOD service modules, which support workspaces by allowing you to customize what aspects of the physical and logical layers are under change control. This change control data is passed back to the presentation layer where you can show it in Management Center workspaces.
The XWARRANTY and XCAREINSTRUCTION data are passed back to the Management Center as part of the userdata element in the Get service you customized in Tutorial: Adding new properties to a WebSphere Commerce service using the data service layer. Because you are using the userdata element, you only need to register the custom tables as managed resources in an XML file, and then run a script to update the workspace schema. You do not need to provide any Java code or additional XML customization.
Learning objectives
After completing this tutorial, you should be able to:
- Enable workspace support for a customized WebSphere Commerce service module
- Update the write schema with the custom table information
- Create a workspace with task groups and tasks by using workspace admin tool
Time required
This tutorial is expected to take 1 hour to complete.
Skill level
Advanced
Audience
This tutorial is intended for developers customizing the Management Center.
System requirements
Before you begin, ensure that you have:
- Installed WebSphere Commerce Developer v7.
- Installed DB2 V9.1
- Verified that the WebSphere Commerce Developer installation is using a DB2 database.
- Enabled workspaces.
- Set the value of StagingEnable to true in the file...
WC_EAR\xml\config\wc-server.xmlAn example follows:
<Staging ContentMgmtEnable="false" DBName="" DBServerName="" DBServerPort="" DBUserID="" DBUserPwd="" DataSourceName="" DatabaseType="" NumWorkspaces="5" ReadPrefix="WCR" StagingEnable="true" WritePrefix="WCW" display="false"/>
Prerequisites
This tutorial uses the schema and Management Center customizations from the Warranty scenario. Complete the following tutorials before proceeding with this one:
- Tutorial: Adding new properties to a WebSphere Commerce service using the data service layer
- Tutorial: Adding new fields in the Catalogs tool
You also need to create the following users:
User ID Organization Roles ConMgr Root Organization Workspace Manager ProMgrA Root Organization Product Manager, Workspace Content Contributor ProMgrB Root Organization Product Manager, Workspace Content Contributor ProMgrApp Root Organization Product Manager, Workspace Task Group Approver
To complete this tutorial, be familiar with the following terms and concepts:
- Workspaces
- Relational databases
- XML
- Management Center
- Data service layer
- Content managed table
You should also be familiar with the techniques for improving the performance of SQL queries under workspaces in the Data Service Layer.
Lessons in this tutorial
- Enable workspace support for the custom tables
In this lesson, you enable workspace support for the custom tables by creating an XML file to identify the table or tables that are managed.
- Update the workspaces write schema
In this lesson, you run the UpdateWorkspaceSchema script to create the custom tables in all of the workspaces. If you change to the WebSphere Commerce database schema, such as adding a new table, these changes must also be made in the workspace schemas. This tool allows you to recalibrate the workspace schemas with the master database schema. Without recalibration, the workspaces will not work with your new changes to the base schema.
- Test the customization
In this lesson, we will test the customization by creating the new workspace, new task groups, and new tasks using the Workspace Administration Tool.