Updating Service Data Objects
If you make changes to the schema, reload the genmodel and regenerate the SDO. Reloading the genmodel file creates the ecore files that are used to construct the SDO Java source for your messages. Prerequisites:
Updating Service Data Objects requires that a genmodel file and service module has been created. If you already have performed these steps, or have an existing genmodel file and service module, you can skip these prerequisite steps.
- Create a WebSphere Commerce service module.
- Create the genmodel file for the Service Data Objects.
- Generate code from an SDO genmodel file.
To update the SDOs:
- Start WebSphere Commerce Developer.
- Right-click the genmodel file and choose Reload.
- Choose Load from an XML schema:
- Browse the workspace to choose the list of schemas to reload from. If all of the changes are internal to existing schemas, then you shouldn't have to do anything at this point; just click Next.
- Select the list of namespaces to include in your genmodel configuration. In this example, select the foundation package. Notice that this schema is dependent on external namespaces, denoted in the bottom tab. Because this is a reload, these dependent schemas are already populated. The first time you load the schema, you would select Browse, and bring in the genmodel file for the dependent schemas.
At this point you should see the Ecore files for your schemas and all of the dependent schemas. For example:
- Double click the genmodel file to generate the source code for these schemas.
Related concepts
WebSphere Commerce services
WebSphere Commerce service module
Service Data Objects (SDO)Related tasks
Create the SDO genmodel file
Generating code from an SDO genmodel file