Mobile App Data State Preservation on Forced Exit
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Mobile devices often terminate database application programs abruptly, leading to loss of data states and connections without user prompts for saving, resulting in inconsistent user experiences and increased network traffic upon re-launch.
Innovation Solution
Implementing a time window for data state preservation upon forced exit, where the mobile device caches and stores connection and data states, allowing for automatic restoration when the application is re-launched, reducing network traffic by only retrieving 'dirty' data.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Speed
If the mobile device forces the application program to terminate immediately, then the device can switch display content quickly, but the data states and connection states are lost
Solution Approach 1:
The system performs preliminary actions by capturing and storing data states and connection states before the forced termination occurs. The event listener detects the forced exit event and immediately stores the current data state (including displayed data and view state) and connection state to persistent storage before the application is fully terminated, ensuring state preservation without delaying the forced exit functionality.
2Productivity
If the application program is re-launched without state restoration, then the program can start quickly, but the user must re-fetch all data from the data store
Solution Approach 1:
The system creates a copy of the data state and connection state from the previous session and stores it persistently. Upon re-launch, instead of fetching all data from the data store, the application restores the copied state locally, including the cached data and connection information, thereby avoiding unnecessary network traffic while maintaining data consistency.
Solution Approach 2:
The system performs preliminary actions by pre-storing the data state and connection state before termination. This preliminary capture of state information eliminates the need for complete data re-fetching during re-launch, reducing network traffic and energy consumption while maintaining productivity.
3Productivity
If the connection is terminated without storing states, then the system resources are freed immediately, but the connection and cached data states are lost
Solution Approach 1:
The system performs preliminary action by capturing the connection state (including connection identifier, data store identifier, and authentication information) and storing it persistently before the forced termination. This allows the connection state to be preserved and restored later without delaying the resource release process.
Solution Approach 2:
The system creates a copy of the connection state and stores it in persistent storage before termination. This copying ensures that the connection information is preserved even after the original connection is closed and resources are freed, enabling rapid reconnection upon re-launch.
Data Source
AI summary
Methods, program products, and systems of maintaining data states upon forced exit are disclosed. In one aspect, an application program executing on the mobile device can maintain a connection to a remote data store and retrieve and cache data from the data store. When the mobile device receives an event that forces the application program to terminate, the mobile device can provide a time window in which the mobile device can perform various state preservation actions. During the time window, the mobile device can store data states, including states of the connection and states of the cached data. When the application program is re-launched, the mobile device can use the stored data states to restore a connection and a displayed view.


