Chapter 5. Evolution: Object-Oriented Database Systems
Chapter 5. Evolution: Object-Oriented Database Systems
Matino
Object-Oriented Database Systems
Chapter 5. Evolution
1
Chapter5. Evolution
Table of Contents
Schema Evolution
Taxonomy of Schema Modification
Schema Invariant
Semantics of Schema Modification
Implementation of Schema Evolution
Instance Evolution
Evolution in Gemstone, O2 and Iris
2
OOPSLA Lab
Chapter5. Evolution
Schema Invariants
Taxonomy of
Schema A’
schema modification
Schema A
Instance Evolution
Instances O
OOPSLA Lab
Instances O’ 3
Chapter5. Evolution
4
OOPSLA Lab
Chapter5. Evolution
5
OOPSLA Lab
Chapter5. Evolution
6
OOPSLA Lab
Chapter5. Evolution
7
OOPSLA Lab
Chapter5. Evolution
Schema Consistency
After schema modification, schema consistency
should be maintained
Schema invariants to make schema consistent
inheritance hierarchy invariant
unique names invariant
single origin invariant
complete inheritance invariant
domain compatibility invariant
preserving information invariant
8
OOPSLA Lab
Chapter5. Evolution
9
OOPSLA Lab
Chapter5. Evolution
10
OOPSLA Lab
Chapter5. Evolution
11
OOPSLA Lab
Chapter5. Evolution
14
OOPSLA Lab
Chapter5. Evolution
17
OOPSLA Lab
Chapter5. Evolution
18
OOPSLA Lab
Chapter5. Evolution
19
OOPSLA Lab
Chapter5. Evolution
20
OOPSLA Lab
Chapter5. Evolution
21
OOPSLA Lab
Chapter5. Evolution
22
OOPSLA Lab
Chapter5. Evolution
23
OOPSLA Lab
Chapter5. Evolution
Deferred approach
24
OOPSLA Lab
Chapter5. Evolution
Screening system
instances are modified when accessed by application
ORION system
Disadvantage
the access to the instances can take longer
25
OOPSLA Lab
Chapter5. Evolution
Consistency of Methods
Structural consistency
Behavioral consistency
ex) if a method refers to deleted or modified attribute?
compile-based solution
• recompile the entire schema and its method cost overhead
interpretation-based solution
• type error or semantically incorrect method can be executed
No general solutions
difficult to determine the effects of a schema modifications
to the set of methods
26
OOPSLA Lab
Chapter5. Evolution
Versions of schema
objects created in a specific schema version are only
visible in that schema version
Object oriented view
no information loss
object is visible in all view, if the conditions are met
27
OOPSLA Lab
Chapter5. Evolution
Instance Evolution
State evolution
modifications to an object’s attributes
28
OOPSLA Lab
Chapter5. Evolution
29
OOPSLA Lab
Chapter5. Evolution
30
OOPSLA Lab
Chapter5. Evolution
31
OOPSLA Lab
Chapter5. Evolution
changeClassTo message
| tempVar |
tempVar := C new. 'Creates an instance of class C'
................…
tempVar changeClassTo: C1
'Converts the instance of class C to the
instance of class C1'
34
OOPSLA Lab
Chapter5. Evolution
Evolution in O2
Schema modifications can’t be done dynamically
Class deletion only for the class
no instances
not used in the definition of other class
State and structural instance evolution
exceptional instances
35
OOPSLA Lab
Chapter5. Evolution
Evolution in Iris
Schema evolution is very limited
Function deletion
type properties can’t be added and deleted dynamically
• automatically deleted if the type is deleted
other functions can always be deleted
DELETE FUNCTION function-name
system automatically deletes all those derived functions
from the deleted functions
36
OOPSLA Lab
Chapter5. Evolution
Type deletion
DELETE TYPE type-name
only if no subtype and not used in defining other types
not result in the deletion of its instances
Dynamic instance evolution
add type and remove type dynamically
default type : UserTypeObject
37
OOPSLA Lab