Tutorials > Content management > Create a content-managed resource
Summary of introducing a content managed resource
The following summarizes the steps required to introduce a new resource into a WebSphere Commerce authoring server.
Lessons learned
By completing this tutorial , you learned about the following concepts and tasks:
- Unmanaged resource
- Create the table into the production ready schema and EJB with access beans.
- Access and manage data directly with access beans within runtime programming model.
- When all resources are created, invoke the workspace allocation ant task script that allocates the definitions of the tables into the workspace schema.
- Managed operational resource
Managed operational resource:
- Create the table into the production ready schema and EJB with access beans.
- Access and manage data directly with access beans within runtime programming model.
- When all resources are created, invoke the workspace allocation ant task script that allocates the definitions of the tables into the workspace schema.
- Create the table into the production ready schema and EJB with access bean.
- Access and manage data directly with access beans within runtime programming model.
- Create the managed operational resource container (if necessary) or add to an existing container. When a new container is to be created, create an object extending from the com.ibm.commerce.context.content.resources.AbstractResourceContainerImpl directly.
- Configure the resource container (if a new one was added) by adding a corresponding entry into the wc-resource-containers.xml.
- Configure the managed operational resource by adding a corresponding entry into the container containers xml file.
- When all resources are created, invoke the workspace allocation ant task script that allocates the definitions of the tables into the workspace schema.
- Managed Content Resource
- Create the table into the production ready schema and EJB with access bean.
- In addition, implement an additional class corresponding to the EJB implementing the com.ibm.commerce.context.content.resources.EntityBeanCreationData interface. The class is a value object that can set and return each and every one of the data properties that is contained within the EJB.
- Implement an ejbCreate(EntityBeanCreationData) within the EJB. This method should create an instance of the EJB given all the properties that are set into the Creation Data object.
- Create the managed content resource container (if necessary) or add to an existing container. When a new container is to be created, create an object extending from the com.ibm.commerce.context.content.resources.AbstractResourceContainerImpl directly.
- Configure the resource container (if a new one was added) by adding a corresponding entry into the wc-resource-containers.xml.
- Configure the managed content resource by adding a corresponding entry into the container containers xml file. The access bean, resource manager and key field data are required in the xml.
- Create command logic to create, update or delete content using the Resource Manager class and not the AccessBean or EJB.
- When all resources are created, invoke the workspace allocation ant task script that allocates the definitions of the tables into the workspace schema.