Publishing business objects

About this task

A new business object is not available for use until you publish it. Once you have done all the previously described things to a new business object and added a state transition diagram, you are ready to publish it. Read about state transition diagrams in "Life cycles".

If you have placed a published business object under revision, none of the changes you make to the business object affect any records until you publish the business object again.

When you publish a business object, if any records were previously created from the business object, they will be made to conform to the new definition of the business object. If you added fields to the business object, publication will add the fields to all records created from the business object. If you deleted fields from the business object, publication will delete the fields from all records created from the business object.

Publishing a business object makes the changes made to the business object available for the creation of new records. Records cannot be created from a business object until the first time the business object is published. Once the business object is published, it becomes possible to create records from the business object.

Clicking the Publish Business Object action for a business object with the Staging Table property set to DataConnect triggers the following activities:

  • If there are any jobs in Processing or Ready state that use the staging table and business object, the publish fails and a message is posted to the user immediately.
  • Because Publish is handled by an agent and is not an immediate action, the Publish agent checks the job state again in case a new job has started or the state of an existing job has changed in the interim. If there are any jobs in Processing or Ready state that use the staging table and business object, the publish fails, a notification is posted to the user, and details about why the publish failed are written to the server.log.

For more information about publishing business objects with the Staging Table field, see "Business object properties" and Application Building for the IBM TRIRIGA Application Platform: Data Management.

It is always best to publish business objects on a quiet system. This is because runtime components using the business object during the publish process could experience unpredictable behavior since there are points in time where the database definition and the business object metadata are not in sync.

After you publish a business object, you can make changes to the business object without being concerned that a partially completed set of changes will be reflected in a newly created record. The changes you make to a business object are not reflected in new records until after you publish the business object again.

You can publish individual business objects by using the Procedure below.

You can also publish multiple business objects at the same time by selecting Utilities > BO Bulk Publish in the Data Modeler menu. When the Business Object Publisher loads, business objects that are not published and are not pending publication are highlighted. By default, the embedded objects are displayed. If you click Show in Manager, you see the unpublished business objects. Verify the business objects that you want to publish are selected, then click Publish BOs. The status changes to Pending Publication. The publish of these business objects might take some time to complete. When the page refreshes, the object ID is displayed for each BO that was not published.

The Procedure shows how to publish individual business objects.

Procedure

  1. Make sure that the details of the business object are visible in the Data Modeler.
  2. Click Tools > Publish BO.
    • While a business object's mapping properties are visible, if the business object is under revision, a Publish action will be at the top of the Data Modeler. Clicking this action is another way to publish a business object.
    • The publication of the business object does not happen immediately. Publication of business objects happens in the background.
  3. You can check whether publication of a business object has finished in two ways:
    • If the state of the business object is Pending Publication, the publication is still underway. If the state of the business object is Published, the publication has finished.
    • When the publication business object has finished being published, a notification is placed in the notification section of your portal. When you see the notification, you know that publication is finished. The subject of the notification will be one of the following, depending on the outcome of the publish:
      • Publication of [BO Name] completed successfully.
      • Publication of [BO Name] completed with warning(s).
      • Publication of [BO Name] completed with error(s).
      • Publication of [BO Name] completed with warning(s) and error(s).
      In the event that the notification subject reported warnings and/or errors, the body of the notification contains more detail about those warnings and/or errors. The Message ID at the end of each message corresponds to a detailed stack trace in the server.log. More information about the server.log can be found in IBM TRIRIGA Application Platform: Administrator Console User Guide.
  4. When an existing business object is republished, the system drops database columns that are no longer used.