Redis-based mass data classified storage method and system
A mass data and storage system technology, applied in the computer field, can solve problems such as increasing response timeout rate, increasing query time, and difficulty in meeting the continuous growth of user data volume, and achieve the effect of reducing memory fragmentation and memory occupation
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Example Embodiment
[0052] Example 1
[0053]According to the present invention, a mass-based mass data classification storage method is provided, including:
[0054] Step S1: Classify the data and define a data category ID for each category data;
[0055] Step S2: For each of the data categories, based on the data size of the corresponding actual service, the number of HASH buckets is calculated; according to the characteristics of the REDIS, the Hash type data is the most space Ziplist data structure storage mode requires Hash Bucket ( That is, the data of the Field stored in a Hash Key is less than 512, so the number N of the HASH bucket is calculated as: n = total data amount / 512, and hindered up.
[0056] Step S3: Use the amount of data identifier ID, data category ID, and data bucket as an incoming factor, performing Hash KEY and FIELD;
[0057] Step S4: The data identifies the data identifies the data as a Hash Value;
[0058] Step S5: Store the Hash Key, Field, and Hash Value into the Redi...
Example Embodiment
[0089] Example 2
[0090] Example 2 is a preferred example of Example 1
[0091] The present invention stores the mass-quantity of data to the REDIS to save memory, and improve access speed, and can classify independently.
[0092] The present invention provides a method of redis based massive data classification storage, including:
[0093] Step 1: Define the user data category ID according to the business category;
[0094] Step 2: Define the amount of user data bucket according to the data level corresponding to the data category ID;
[0095] Step 3: The user data identifier of the string type, the data category ID, the data category ID, the data category ID, using the HASH algorithm A calculate the integer type hashing result A;
[0096] Step 4: Take the intensive type of hash result A as a Hash Key of the REDIS's HASH data type;
[0097] Step 5: A user data identifying the string type as a unique factor, calculates the integer type has been obtained by the HASH algorithm B, ...
PUM
Abstract
Description
Claims
Application Information
- R&D Engineer
- R&D Manager
- IP Professional
- Industry Leading Data Capabilities
- Powerful AI technology
- Patent DNA Extraction
Browse by: Latest US Patents, China's latest patents, Technical Efficacy Thesaurus, Application Domain, Technology Topic.
© 2024 PatSnap. All rights reserved.Legal|Privacy policy|Modern Slavery Act Transparency Statement|Sitemap