Workspaces data model

Content management is achieved through the use of workspaces. Each workspace is comprised of three database schemas. The following schemas are used in workspaces:

The data within these schemas is categorized as one of the following types of data:

The base schema contains data that is identical to the production environments. All workspaces draw from this common repository of data but none of their working changes are reflected here. It is in the individual write schemas that any uncommitted changes are stored, thereby isolating workspace 1 from changes in workspace 2. However, when users preview their changes, the write and base schemas are hidden behind the read schema. The read schema first checks the write schema for the requested data and, if it is not found there, then goes to the base schema. Essentially, the read schema consolidates all the altered and unaltered data from the write and base schemas and packages it as a single entity.

Within a workspace context, updates to a resource are directed to the write schema, whereas retrieving data for a resource is directed to the read schema. Each table within the WebSphere Commerce data model is in one of the following classifications that determine the definition of the read and write schema:

Each of the assets defines a table within the Production-Ready schema.


Managed content assets

The following figure illustrates the workspace data model for a content managed resource.

This type of resource has a physical table allocated in the write schema to store changes from within a workspace. A database view of the same name is defined within the read schema that is a union of the write schema table overriding the production-ready schema table. The table within the write schema has nearly the same structure as the production-ready schema with the following exceptions:


Managed operational assets

The following figure illustrates the workspace data model for a managed operational resource. This type of resource has a corresponding table allocated in the workspace write schema to record changes within the workspace resulting from a preview. The read schema is defined as an alias to the write schema table so that the data is only viewable within the workspace.

The table within the workspaces has nearly the same structure as the production-ready schema with the following exceptions:


Unmanaged assets

The following figure illustrates the workspace data model for an unmanaged resource.

This type of resource does not participate in a workspace. The data in the production-ready schema is always accessed directly from within a workspace and as such, both the read and write schemas are aliases to the production-ready schema table.


Related reference
Workspaces best practices
Workspaces limitations
Workspace state flows