A method and terminal for optimizing data deletion
An optimization method and data technology, applied in database indexing, electronic digital data processing, structured data retrieval, etc., to achieve the effect of improving efficiency
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0059] Please refer to figure 1 , the first embodiment of the present invention is:
[0060] An optimization method for data deletion, comprising the steps of:
[0061] S1. While saving the channel information to the hashmap data set, create a treemap data in the treemap data set. The key of the treemap data is the expiration timestamp of the channel information and the value is the list structure of the channel ID that stores the channel information;
[0062] S2. Scan the treemap data set, delete the channel information corresponding to the channel ID corresponding to the key whose expiration timestamp is less than or equal to the current time in the hashmap dataset, and delete the key whose expiration timestamp is less than or equal to the current time in the treemap dataset. treemap data.
[0063] In this embodiment, the treemap data set in step S1 performs an ascending key sorting operation. At this time, step S2 further includes: when scanning the treemap data where the...
Embodiment 2
[0071] Please refer to figure 1 , the second embodiment of the present invention is:
[0072] An optimization method for data deletion, on the basis of the above-mentioned Embodiment 1, the specific implementation process of S2 is replaced as follows:
[0073] Obtain the arrangement position of the first treemap data in the treemap dataset where the expiration timestamp closest to the current time is located in the treemap dataset, and determine whether the expiration timestamps before the first treemap data are all less than or equal to the current time, and if so, Then delete the channel information corresponding to the channel ID in all treemap data whose arrangement position is before the first treemap data in the hashmap data set;
[0074] If the expiration timestamps whose arrangement positions are before the first treemap data are all greater than the current time, the channel information corresponding to the channel IDs in all treemap data whose arrangement positions ...
Embodiment 3
[0077] Please refer to figure 2 , the third embodiment of the present invention is:
[0078] An optimized terminal 1 for data deletion includes a memory 3, a processor 2, and a computer program stored in the memory 3 and running on the processor 2. The processor 2 implements the steps of the first embodiment when executing the computer program.
PUM
Login to View More Abstract
Description
Claims
Application Information
Login to View More 

