Inserting, Updating and Deleting Objects

Garbage Collector (GC) Automatically Removes Unused Objects

Objects in the database are managed using two methods: store and delete.

The Garbage Collector (GC) runs automatically after each transaction.

The store method stores the object and its data structure in the database.

New objects are added, and old ones (existing) are updated in the database.

The value of the object ID field serves as the object's identity and is unique across all objects in the database.

In the image below, the ID values inside the circles identify the objects. The different circle colors indicate various Java object classes.

Common objects between different data structures are shared in the database.

The Garbage Collector (GC) ensures that only necessary objects remain in the database after each transaction.

storeObjectsEx1Pic1

The delete method attempts to remove the object and its associated data structure from the database.

However, the Garbage Collector (GC) determines at the end of the transaction which objects are actually removed from the database.

If an object that is still needed in another data structure is a candidate for deletion, the GC will not remove it. Refer to the objects with ID values 4 and 5 below, crossed out with a red dashed line.

deleteMethod1Ex1Pic1

Another call to the delete method for object2 removes it and all associated objects in its data structure from the database.

This also includes objects 4 and 5, which were shared with object1 and remained in the database after object1's deletion.

deleteMethod2Ex1Pic1

Note that the above examples represent only a small portion of what is involved in the Garbage Collector (GC) and the processes of inserting, updating, and deleting objects in a database.

Unfortunately, we are unable to provide additional examples on this site, as doing so would disclose too much about this unreleased technology

Links to other pages on this site.


Page content © 2024 

company name

Contact us:

mail address