Bundling metadata as a new object

About this task

This procedure has a number of desirable properties, not least of which is the resiliency against client failures mid-transaction. The use of a monotonically incrementing revision number allows disaster recovery to insert the newest revision during database restoration.

Procedure

  1. Start a database transaction.
  2. Update database with new metadata.
  3. Generate a new revision strictly greater than the old metadata revision.
    The old revision can be obtained from the database table.
  4. Generate a new metadata bundle.
    A bundle consists of metadata in an application-parseable representation, with the new revision number and the permanent OID generated by the application.
  5. Store this bundle as a new object.
  6. Update metadata OID and metadata revision in the database.
  7. Commit database transaction.
  8. Remove old metadata object from SOV.