Client-Side Session Cache for Database Recovery
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
System failures in database applications lead to the loss of session context information, as client-server sessions become disconnected, causing locale and other settings to be reset to default values, which can affect queries and require additional defensive coding to mitigate.
Innovation Solution
Implementing client-side session caching, where session context information is stored in a cache on the client computer, allowing for the recovery of session settings upon reconnection by replaying cached updates to the DBMS, reducing the need for redo logs and redistributing workload from the DBMS.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If session context information is stored on the server side, then recovery is possible after system failures, but session disconnection still causes loss of context information and requires additional defensive coding
Solution Approach 1:
The patent applies preliminary action by having the client proactively cache session context information locally before any failure occurs. The client maintains a local cache of session context that can be immediately applied upon reconnection, eliminating the information loss that would otherwise occur during server-side session disruption. This pre-positioning of recovery data at the client side resolves the contradiction between reliability and information loss.
2Reliability
If defensive code is added to guard against session failures, then application robustness improves, but system complexity increases
Solution Approach 1:
The patent implements self-service by enabling the client to automatically manage its own session context through local caching. When a connection is restored, the client autonomously retrieves and applies its cached session context without requiring complex defensive code on either the client or server side. This self-managed approach maintains application robustness while minimizing the complexity of defensive programming.
3Productivity
If all session context is cached on the client side, then session recovery is faster, but storage requirements on the client increase
Solution Approach 1:
The patent applies the extraction principle by selectively caching only the essential session context information that is necessary for recovery, rather than caching all possible session data. The client extracts and stores only the critical context elements locally, enabling fast recovery while maintaining minimal storage requirements. This selective approach resolves the contradiction between recovery speed and storage volume.
Data Source
Figure 1
Figure 2
Figure 3
AI summary
A client computer establishes one or more sessions with a DBMS. Session context information for each session is cached in a client-side session cache. When a session disconnection is detected, the session recovery includes establishing a new session with the DBMS, and restoring the session context of the disconnected session from the session information of the disconnected session that is stored in the session cache.