Storage Strategy in a Repository Database
The database storage model in Microsoft® SQL Server™ 2000 Meta Data Services differs from the run-time object model. While the run-time object model is designed to accommodate run-time operations conveniently, the database model is designed to accommodate storage efficiently.
To save space in the database, Meta Data Services can sometimes store a single copy of a property value, even if that property value describes many object versions. Similarly, Meta Data Services can sometimes store a single copy of a relationship, even if many different object versions have that relationship.
Meta Data Services anticipates which object versions are especially likely to share property values and relationships and which object versions are less likely to. The repository engine uses these guidelines:
- Two versions of the same object are likely to share property values and collections, but two versions of different objects are less likely to do so. In other words, if two object versions are not on the same version graph, they are not especially likely to share property values or relationships. For more information, see Version Graph.
- Within a version graph, two versions that are near each other are more likely to share values; two versions that are far apart are less likely to share values. The repository engine arranges each version graph into branches. For more information, see Branches in the Version Graph. Each branch contains versions that are especially likely to share values.
- Although property values and collections can change, they do not change back and forth frequently. More commonly, a value holds for a few consecutive versions of an object, and then that value changes to a new value, which holds for a few more versions of the object. Thus, when Meta Data Services stores a property value, it stores the property value for an entire range of object versions. For more information, see Ranges in the Version Graph.
Similarly, in a single row of the RTblRelships table, Meta Data Services can indicate that every object version in a range (of origin object versions) has a relationship to every object version in a range (of destination object versions).