Object Buffer for Reducing Database Access in O-O Systems
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Existing object-oriented systems require frequent database access to manage inactive and active versions of objects, leading to inefficiencies as they cannot store both versions simultaneously, forcing users to bring objects into a consistent state before saving, which is burdensome and resource-intensive.
Innovation Solution
A buffer capable of storing both active and inactive versions of an object, allowing for simultaneous storage and enabling the user to save inactive content to the database only when desired, reducing the need for database access until persistence is required.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Productivity
If a buffer stores only one version of an object (active or inactive), then database access is required to retrieve or store the other version, but this increases database access frequency and reduces system efficiency
Solution Approach 1:
The buffer is segmented into multiple storage areas: an active version storage area for storing active object versions, an inactive version storage area for storing inactive object versions, and a work area for processing. This segmentation allows the buffer to independently store both active and inactive versions without requiring database access, thereby reducing database access frequency and improving system efficiency
Solution Approach 2:
The buffer structure is extended from a single-dimension storage (one version at a time) to a multi-dimension storage structure that can simultaneously hold active versions, inactive versions, and work areas. This dimensional expansion allows all necessary object versions to coexist in memory, eliminating the need for frequent database accesses to retrieve or store versions
2Reliability
If users must bring objects into a consistent state before saving to database, then data consistency is maintained, but this increases operational complexity and user burden
Solution Approach 1:
The system performs preliminary consistency validation by maintaining activation protocols that evaluate modifications against object models before they are committed. The buffer structure allows users to save inactive content to the database without immediate consistency checks, deferring validation to a later activation phase. This preliminary action approach maintains data consistency while reducing immediate user burden during the saving process
Solution Approach 2:
The buffer acts as an intermediary layer between the user interface and the database, decoupling the saving operation from the consistency validation. Users can save objects to the buffer in an inactive state without immediate consistency checks, and the system handles consistency validation separately during the activation phase. This intermediary mechanism maintains reliability while improving ease of operation
3Ease of operation
If the buffer frequently accesses the database to retrieve active versions, then the active version can be restored, but this increases resource consumption and reduces operation speed
Solution Approach 1:
The buffer is segmented into distinct storage areas for active versions, inactive versions, and work areas. The inactive version storage area specifically stores inactive object versions, eliminating the need to access the database to retrieve them for rollback operations. This segmentation enables rollback capability while minimizing resource consumption by keeping all necessary versions in memory
Solution Approach 2:
Instead of storing only one version and retrieving the other from the database, the system creates copies of object versions and stores them in appropriate buffer areas. Inactive versions are copied and stored in the inactive version storage area when modifications occur, allowing immediate rollback without database access. This copying mechanism enables easy rollback while reducing resource consumption compared to frequent database accesses
Data Source
AI summary
Systems and methods for minimizing database accesses in an object-oriented system may involve opening an object in a buffer, wherein the buffer is operative to store both an active version of the object comprising active content and an inactive version of the object comprising the inactive content modified by one or more inactive requests. An activation manager may be operative to determine whether the one or more inactive requests are consistent with an applicable object model. Because the buffer stores is operative to store both an active version and an inactive version of the object, it may implement commands to change the object between the inactive and active states without accessing the database. Upon receiving a flush command, the buffer may also be operative to make any version of the object stored in the buffer at that time—whether active, inactive, or both—persistent on the database.


