Method and system for realizing block chain cold and hot data differentiated storage

By establishing a unified index on the blockchain platform and utilizing the different performance storage spaces of the main chain and sub-chains, combined with smart contracts, cold data migration is realized, which solves the problem of insufficient identification accuracy of hot and cold data in the blockchain and improves storage efficiency. and availability, reducing costs.

CN118760719APending Publication Date: 2024-10-11SHANGHAI GOLDEN BRIDGE INFOTECH CO LTD
View PDF 0 Cites 3 Cited by

Patent Information

Application Number
CN202410517550.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-04-28
Publication Date
2024-10-11

AI Technical Summary

Technical Problem

Existing technology is difficult to effectively identify and separate hot and cold data in the blockchain, resulting in low storage efficiency and high data storage costs, and cannot meet the needs of multi-source heterogeneous data on-chain storage.

Method used

By establishing a unified index on the blockchain platform, data labels are automatically updated based on the records of the certificate content, and the different performance storage spaces of the main chain and sub-chains are used, combined with smart contracts, to achieve automatic migration of cold data and optimize the use of storage resources.

Benefits of technology

It improves the efficiency and availability of blockchain storage, reduces storage costs, realizes efficient distinction and reasonable planning of hot and cold data, and improves the reading performance of hot data.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118760719A_ABST
    Figure CN118760719A_ABST
Patent Text Reader

Abstract

The invention provides a block chain cold and hot data differentiated storage method and system, and the method comprises the steps: building a unified index on a block chain platform according to the evidence storage content, and automatically updating the data label of the evidence storage content according to the record of the evidence storage content in the unified index; and according to the updated data label of the evidence storage content, carrying out storage space change of the evidence storage content on the main chain and the sub-chain, and recording the storage space change into the unified index. According to the method, the storage performance of the block chain and the access speed of the data are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of blockchain technology, and in particular to a method and system for implementing differentiated storage of hot and cold data in blockchain. Background Art

[0002] As enterprise business continues to change, the business configuration data in the enterprise configuration system has exploded. The storage demand brought about by the surge in data volume continues to increase. Enterprises optimize storage space by establishing a tiered storage architecture. In order to improve the space utilization rate in the tiered storage system, enterprises divide data into frequently accessed hot data and infrequently accessed cold data, and match data access characteristics with storage device performance to avoid storage pollution caused by cold data residing in high-performance storage layers. The recognition accuracy of hot and cold data will directly affect the data access efficiency of the tiered storage system.

[0003] Therefore, it is of great significance to carry out research on storage mechanisms for hot and cold data. The current research on hot and cold data originated from the hierarchical design of computer cache, which cannot adapt to the needs of blockchain technology. When using existing technologies to store multi-source heterogeneous data on the chain, it faces problems such as low storage efficiency and high data storage costs.

[0004] In view of this, the present invention is proposed. Summary of the invention

[0005] The purpose of the present invention is to provide a method and system for realizing the differentiated storage of hot and cold data in blockchain, and to divide the on-chain data into different data tags. On the basis of the main chain, one or more sub-chains are created, and different sub-chains are used to distinguish and store data with different data tags. At the same time, data exchange is realized with the main chain through sub-chain technology, so as to achieve high availability and scalability of blockchain storage resources while meeting performance requirements.

[0006] In order to achieve the above-mentioned purpose of the present invention, the following technical solutions are particularly adopted:

[0007] The present invention discloses a method for realizing the differentiated storage of hot and cold data in blockchain, comprising the following steps:

[0008] On the blockchain platform, a unified index is established according to the stored content, and the data tag of the stored content is automatically updated according to the record of the stored content in the unified index;

[0009] According to the data tag of the updated evidence content, the storage space of the evidence content is changed on the main chain and the sub-chain, and the storage space change is recorded in the unified index.

[0010] Use storage media with different performance to build storage space for the main chain and sub-chain, intelligently divide the data according to the data tag of the chain data and the reading frequency of the unique evidence index, comprehensively plan the storage content on the chain, and use smart contracts to trigger the automatic migration of cold data on the chain to the sub-chain, effectively improving the efficiency of hot data reading in the main chain.

[0011] Preferably, the method for establishing a unified index based on the stored evidence content includes the following steps:

[0012] Receive the evidence content, and create the unified index using metadata of the information of the evidence content, wherein the metadata of the information of the evidence content includes a hash value of the evidence content, a creation time, and an evidence number.

[0013] Generate a Hash based on the unified index, and synchronously add the Hash to the on-chain evidence storage message.

[0014] Preferably, the types of the unified index include:

[0015] Transaction index: used to store and quickly retrieve the data of the evidence content, including the evidence hash, sender, receiver or evidence type;

[0016] Block index: used to store and manage block data, including block header information and transaction list.

[0017] Through the transaction index, users can quickly find specific evidence records based on information such as evidence hash, sender, receiver, or evidence type. The block index can help users quickly locate the location of a block and trace back to a specific block from the starting block of the blockchain, improving the retrieval efficiency of blockchain data.

[0018] Preferably, the method for automatically updating the data tag of the evidence content includes: selecting any one of the methods for judgment according to the evidence creation time, the access popularity, and the last call time:

[0019] Wherein, judging by the creation time of the evidence means judging by the span between the creation time of the evidence content and the current time node;

[0020] The access popularity refers to judging based on the total number of times the stored content is called for verification;

[0021] Among them, judging by the last call time refers to judging according to the span from the last access of the stored content to the current time node.

[0022] Hot data refers to data that is frequently accessed, such as process data; cold data refers to data that is infrequently accessed or archived, such as result data. The hot and cold data types are judged based on the three logics of evidence creation time, access popularity, and last call time, which facilitates the planning of data storage on the blockchain.

[0023] Preferably, the data tag type of the stored evidence content includes: any one of a hot tag, a warm tag, a cold tag, and a frozen tag.

[0024] Preferably, the method for automatically updating the data tag of the stored content includes: a hot tag identification method, a warm tag identification method, a cold tag identification method, and a frozen tag identification method:

[0025] The hot tag identification method refers to that after the content is added, when the span between the last access time and the current time node is less than 23 hours, and when the number of accesses in the last 7 days is greater than 10 times, the data tag of the content is updated to a hot tag when the above three situations occur;

[0026] The warm tag identification method refers to that when there is no subsequent operation on the stored content 30 days after it is added, when the span between the last access time and the current time node is greater than 48 hours, and when the number of accesses in the last 7 days is less than 10 times, the data tag of the stored content is updated to the warm tag when the above three situations occur;

[0027] The cold tag identification method is that when 60 days have passed since the stored content entered the warm tag phase, when the span between the last access time and the current time node is greater than 60 days, and when the number of accesses in the last 30 days is less than 5 times, the data tag of the stored content is updated to a cold tag when the above three situations occur;

[0028] Among them, the frozen tag identification method refers to that when 90 days have passed since the evidence content entered the cold tag stage, the data tag of the evidence content is updated to a frozen tag.

[0029] Preferably, the method for changing the storage space of the evidence content is any one of the hot tag method, the warm tag method, the cold tag method, and the frozen tag method:

[0030] The hot tag method means that when the data tag of the stored content is the hot tag, the block volume in the storage space of the stored content reaches 10MB, triggering block splitting, automatically updating the unified index and initiating the update of the data tag of the stored content on the chain, and updating and optimizing the block position to achieve the purpose of storage space change;

[0031] The warm tag method means that when the data tag of the stored content is a warm tag, the block size in the storage space of the stored content is less than 2MB, triggering block merging, automatically updating the unified index and initiating the data tag update of the stored content on the chain, and updating and optimizing the block position to achieve the purpose of storage space change;

[0032] The cold tag method means that when the data tag of the evidence content is a cold tag, the block volume in the storage space of the evidence content is less than 2MB, triggering block merging, automatically updating the unified index and initiating the data tag update of the evidence content on the chain, while updating and optimizing the block position, starting cross-chain migration, migrating the updated evidence content to the subchain for storage, clearing the original evidence content on the main chain, and updating the unified index to achieve the purpose of storage space change;

[0033] The frozen tag method means that when the data tag of the evidence content is a frozen tag, the block volume in the storage space of the evidence content is less than 2MB, triggering block merging, automatically updating the unified index and initiating the data tag update of the on-chain evidence content, while updating and optimizing the block position, and then starting the cross-chain migration, migrating the evidence content to the sub-chain for storage, clearing the original evidence content of the main chain, and updating the unified index to achieve the purpose of storage space change.

[0034] The data is divided into 4 categories. Hot and warm types are stored on the main chain, and cold and frozen types are stored on the sub-chain. The sub-chain can also choose different storage media according to the data storage requirements. Because hot type data will increase as new data is continuously stored, and the existence time of hot type data and warm type data is shorter than that of cold type data and frozen type data, and the access frequency is high, so it is necessary to split the hot type data and warm type data into blocks. After changing to cold type and frozen type, the access frequency is low and high access speed is not required, so the blocks are merged for easy storage.

[0035] The present invention discloses a system for realizing the differentiated storage of hot and cold data in blockchain, including the following modules:

[0036] Unified index module: On the blockchain platform, a unified index is established based on the stored content;

[0037] Update data type label module: automatically update the data label of the stored content according to the record of the stored content in the unified index;

[0038] Evidence data migration module: According to the data tag of the updated evidence content, the storage space of the evidence content is changed on the main chain and the sub-chain, and the storage space change is recorded in the unified index.

[0039] The present invention discloses a computer-readable storage medium, on which a computer program is stored, and when the program is executed, the steps of any method of the first aspect are implemented.

[0040] The present invention provides a computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the steps of any method of the first aspect are implemented. BRIEF DESCRIPTION OF THE DRAWINGS

[0041] Various other advantages and benefits will become apparent to those of ordinary skill in the art by reading the detailed description of the preferred embodiments below. The accompanying drawings are only for the purpose of illustrating the preferred embodiments and are not to be considered as limiting the present invention. Moreover, the same reference symbols are used throughout the accompanying drawings to represent the same components. In the accompanying drawings:

[0042] Figure 1 A flowchart of the method provided by the embodiment of the present invention;

[0043] Figure 2 A technical block diagram of the method provided by an embodiment of the present invention;

[0044] Figure 3 A diagram of the cross-chain verification steps based on the unified evidence Hash provided in the embodiment of the present invention;

[0045] Figure 4 A schematic diagram of the structure of a system for implementing differentiated storage of hot and cold blockchain data provided by an embodiment of the present invention;

[0046] Figure 5 A flowchart of a computer device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0047] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present disclosure. Instead, they are merely examples of devices and methods consistent with some aspects of the present disclosure as detailed in the appended claims.

[0048] The terms used in this disclosure are for the purpose of describing specific embodiments only and are not intended to limit the disclosure. The singular forms of "a", "said" and "the" used in this disclosure and the appended claims are also intended to include plural forms unless the context clearly indicates otherwise. It should also be understood that the term "and / or" used herein refers to and includes any or all possible combinations of one or more associated listed items.

[0049] It should be understood that although the terms first, second, third, etc. may be used in the present disclosure to describe various information, such information should not be limited to these terms. These terms are only used to distinguish the same type of information from each other. For example, without departing from the scope of the present disclosure, the first information may also be referred to as the second information, and similarly, the second information may also be referred to as the first information. Depending on the context, the word "if" as used herein may be interpreted as "at the time of" or "when" or "in response to determining".

[0050] The method and technical steps of the present invention are as follows Figure 1 As shown:

[0051] S1: Establish a unified index-based evidence storage interface service, provide data status fields such as new creation, update, and archiving from the evidence storage message, receive the evidence data of the business system, establish a unified evidence storage index module, generate a hash based on the index, and synchronously add the on-chain evidence storage message.

[0052] Data status field construction and definition:

[0053] New construction;

[0054] renew;

[0055] Archive;

[0056] freeze;

[0057] Unified evidence index:

[0058] Build a unified evidence index module and use metadata index: Use metadata of evidence information to create indexes, such as the hash value of the file, creation time, evidence number, etc., to build an index database. Realize fast query of unified evidence index, and use these metadata to quickly locate specific evidence records.

[0059] Establishing a unified evidence index can quickly locate evidence data and obtain all access records of the evidence data, solving the problem that records of access to evidence data from multiple channels are difficult to unify and count, while providing data for subsequent steps.

[0060] S2: According to the data status field provided by the business system and combined with the storage verification access record based on the unified storage index, the data type label of the storage content is automatically added or updated.

[0061] Intelligent identification of hot and cold data type labels:

[0062] The main recognition logic includes:

[0063] According to the time of evidence creation: In the early stage of evidence data writing, users pay more attention to it and access it frequently. At this time, the data is hot data. However, as time goes by, the access frequency of old data will become lower and lower, with only a few queries or even no queries at all. At this time, the data is cold data;

[0064] According to access popularity: distinguish between hot and cold data according to the total number of verification calls for the stored data;

[0065] According to the last call time: the span from the last time the evidence data was accessed to the current time node.

[0066] Intelligent identification strategy rules:

[0067] Hot tag identification:

[0068] The state of the evidence data is newly created, the min age attribute is not configured, and the default value is 0ms, which means that the evidence data belongs to the hot tag immediately after it is added.

[0069] If the span between the last access time and the current time node is less than 23 hours, the cross time attribute is automatically filled and belongs to the hot tag.

[0070] If the number of visits in the last 7 days is greater than 10 times, the access times attribute is automatically filled in and belongs to the hot tag.

[0071] Warm label identification:

[0072] The state of the evidence data is updated, and the value of the min age attribute is 30d, which means that when there is no subsequent operation after the evidence data is sent for 30 days, the index data enters the warm stage.

[0073] If the span between the last access time and the current time node is greater than 48 hours, the cross time attribute is automatically filled and belongs to the warm tag.

[0074] If the number of visits in the last 7 days is less than 10, the access times attribute is automatically filled in and belongs to the warm tag.

[0075] Cold tag identification:

[0076] The status of the evidence data is update or archive, and the min age attribute value is 60d, which means that when the index data enters the warm stage, it will enter the cold stage 60 days later.

[0077] If the span between the last access time and the current time node is greater than 60 days, the cross time attribute is automatically filled and belongs to the cold tag.

[0078] If the number of visits in the last 30 days is less than 5, the access times attribute is automatically filled and belongs to the cold tag.

[0079] Frozen tag identification:

[0080] The status of the evidence data is frozen, and the min age attribute value is 90d, which means that the index data will enter the frozen stage 90 days after entering the cold stage.

[0081] Data is divided into four types: hot, warm, cold, and frozen. Hot data and worm data are commonly used data and are stored in high-performance storage media with fast read and write speeds and a large number of read and write times, which is convenient for reading and writing. Cold data is stored in storage media with lower performance. You can also select appropriate storage media according to the data type, which effectively saves storage costs while ensuring storage performance.

[0082] S3: Add DAPP contract application on the blockchain platform to realize the automatic cross-chain migration of evidence data on the main chain to the sub-chain according to the data type label change of the evidence content, thus freeing up the storage space of the main chain. The rules for the automatic tiered storage contract application of hot and cold data are as follows:

[0083] Hot tag data triggers smart contract rules: check the conditions for block segmentation, trigger block segmentation when the main block volume reaches 10MB, automatically update the index database and initiate label updates for on-chain evidence content, and update and optimize the storage block position in the original evidence block.

[0084] The warm tag data triggers the smart contract rules: check the conditions for block merging. If the main block size is less than 2MB, the block merging is triggered. The index database is automatically updated and the tag update of the on-chain evidence content is initiated. At the same time, the storage block position in the original evidence block is updated and optimized.

[0085] Cold tag data triggers smart contract rules:

[0086] Start block merging. When the size of the main block is less than 2MB, the block merging is triggered. The index database is automatically updated and the label update of the on-chain evidence content is initiated. At the same time, the storage block position in the original evidence block is updated and optimized.

[0087] Initiate cross-chain migration and migrate the updated evidence content to the sub-chain for storage.

[0088] Clear the original evidence content of the main chain and only keep the sub-chain transfer index record on the main chain.

[0089] Frozen tag data triggers smart contract rules:

[0090] Start block merging. When the size of the main block is less than 2MB, the block merging is triggered. The index database is automatically updated and the label update of the on-chain evidence content is initiated. At the same time, the storage block position in the original evidence block is updated and optimized.

[0091] Initiate cross-chain migration and migrate the updated evidence content to the sub-chain for storage.

[0092] Clear the original evidence content of the main chain, update the sub-chain evidence index to the index database, and notify the business system of the change in the evidence index.

[0093] By splitting and merging blocks of evidence data and migrating them across chains, the location of storage blocks is rationally planned, and infrequently accessed cold data is migrated to sub-chain storage, while the main chain retains frequently accessed hot data, effectively improving the storage performance of the blockchain.

[0094] Cold data migrated to the sub-chain can be cross-chain verified through the unified evidence index hash ( Figure 3 ).

[0095] like Figure 2 As shown, the present invention is technically divided into two frameworks, the business system and the blockchain platform. The function of the business system is to process the data tags of the evidence data and plan the blockchain storage, intelligently divide the data according to the status tags of the chain data and the reading frequency of the unique evidence index, comprehensively plan the storage content on the chain, and use smart contracts to trigger the automatic migration of cold data on the chain to the sub-chain, effectively improving the efficiency of hot data reading in the main chain. The function of the blockchain platform is to store data, and use storage media with different performance to build data storage space for the main chain and sub-chain, so as to reduce costs and ensure high availability of storage resources while meeting performance requirements.

[0096] Reference Figure 4 As shown, the present invention also provides a system for implementing differentiated storage of hot and cold data in blockchain, including the following modules:

[0097] Unified index module: establishes a unified index based on the stored data, and the unified index includes a data type label;

[0098] Update data type label module: automatically update the data type label of the evidence;

[0099] Evidence data migration module: According to the updated evidence data type label, the storage space of the evidence data is changed on the main chain and the sub-chain and the storage space change information is recorded in the unified index.

[0100] The system is mainly composed of the above three modules. Through the construction of this system, the purpose of parallel operation can be achieved by mounting the same file system at the same time.

[0101] In specific implementation, the above modules can be implemented as independent entities, or can be arbitrarily combined and implemented as the same or several entities. The specific implementation of the above units can refer to the previous method embodiments, which will not be repeated here.

[0102] Figure 5 This is a schematic diagram of the structure of a computer device disclosed in the present invention. Figure 5 As shown, the computer device 400 includes at least a memory 402 and a processor 401; the memory 402 is connected to the processor via a communication bus 403, and is used to store computer instructions executable by the processor 401, and the processor 301 is used to read computer instructions from the memory 402 to implement the steps of the insertion method of any of the above embodiments.

[0103] For the above-mentioned device embodiments, since they basically correspond to the method embodiments, the relevant parts can refer to the partial description of the method embodiments. The device embodiments described above are only schematic, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the disclosed solution. A person of ordinary skill in the art can understand and implement it without paying any creative work.

[0104] Computer readable media suitable for storing computer program instructions and data include all forms of non-volatile memory, media and memory devices, including, for example, semiconductor memory devices (e.g., EPROM, EEPROM and flash memory devices), magnetic disks (e.g., internal disks or removable disks), magneto-optical disks, and CD ROM and DVD-ROM disks. The processor and memory may be supplemented by, or incorporated in, special purpose logic circuits.

[0105] Finally, it should be noted that although this specification contains many specific implementation details, these should not be interpreted as limiting the scope of any invention or the scope of protection claimed, but are mainly used to describe the features of specific embodiments of specific inventions. Certain features described in multiple embodiments within this specification may also be implemented in combination in a single embodiment. On the other hand, the various features described in a single embodiment may also be implemented separately in multiple embodiments or in any suitable sub-combination. In addition, although features may work in certain combinations as described above and even initially claimed as such, one or more features from the claimed combination may be removed from the combination in some cases, and the claimed combination may point to a sub-combination or a variation of a sub-combination.

[0106] Similarly, although operations are depicted in a particular order in the accompanying drawings, this should not be understood as requiring that these operations be performed in the particular order shown or performed sequentially, or requiring that all illustrated operations be performed to achieve the desired results. In some cases, multitasking and parallel processing may be advantageous. In addition, the separation of various system modules and components in the above-described embodiments should not be understood as requiring such separation in all embodiments, and it should be understood that the described program components and systems can generally be integrated together in a single software product, or packaged into multiple software products.

[0107] Thus, specific embodiments of the subject matter have been described. Other embodiments are within the scope of the appended claims. In some cases, the actions recited in the claims can be performed in a different order and still achieve the desired results. In addition, the processes depicted in the drawings do not necessarily require the particular order or sequential order shown to achieve the desired results. In some implementations, multitasking and parallel processing may be advantageous.

[0108] The above description is only a preferred embodiment of the present disclosure and is not intended to limit the present disclosure. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present disclosure shall be included in the scope of protection of the present disclosure.

Claims

1. A method for realizing the differentiated storage of hot and cold data in blockchain, characterized in that: The following steps are involved: On the blockchain platform, a unified index is established according to the stored content, and the data tag of the stored content is automatically updated according to the record of the stored content in the unified index; According to the data tag of the updated evidence content, the storage space of the evidence content is changed on the main chain and the sub-chain, and the storage space change is recorded in the unified index.

2. The method for realizing the differentiated storage of hot and cold data in blockchain according to claim 1 is characterized in that: The method for establishing a unified index based on the stored evidence content comprises the following steps: Receiving the stored content, and creating the unified index using metadata of the information of the stored content, wherein the metadata of the information of the stored content includes a hash value of the stored content, a creation time, and a storage number; Generate a Hash based on the unified index, and synchronously add the Hash to the on-chain evidence storage message.

3. The method for realizing the differentiated storage of hot and cold data in blockchain according to claim 1 is characterized in that: The types of unified indexes include: Transaction index: used to store and quickly retrieve the data of the evidence content, including the evidence hash, sender, receiver or evidence type; Block index: used to store and manage block data, including block header information and transaction list.

4. The method for realizing the differentiated storage of hot and cold data in blockchain according to claim 1 is characterized in that: The method for automatically updating the data tag of the evidence content includes: selecting any one of the methods for judging according to the evidence creation time, the access popularity, and the last call time: Wherein, judging by the creation time of the evidence means judging by the span between the creation time of the evidence content and the current time node; Wherein, the access popularity refers to judging according to the total number of times the stored content is called for verification; Among them, judging by the last call time refers to judging according to the span from the last access of the stored content to the current time node.

5. The method for realizing the differentiated storage of hot and cold data in blockchain according to any one of claims 1 to 4, characterized in that: The data tag type of the stored content includes: any one of a hot tag, a warm tag, a cold tag, and a frozen tag.

6. The method for implementing the differentiated storage of hot and cold data in blockchain according to any one of claims 1 to 5, characterized in that: The method for automatically updating the data tag of the stored content includes: a hot tag identification method, a warm tag identification method, a cold tag identification method, and a frozen tag identification method: The hot tag identification method refers to that after the content is added, when the span between the last access time and the current time node is less than 23 hours, and when the number of accesses in the last 7 days is greater than 10 times, the data tag of the content is updated to a hot tag when the above three situations occur; The warm tag identification method refers to that when there is no subsequent operation on the stored content 30 days after it is added, when the span between the last access time and the current time node is greater than 48 hours, and when the number of accesses in the last 7 days is less than 10 times, the data tag of the stored content is updated to the warm tag when the above three situations occur; The cold tag identification method is that when 60 days have passed since the stored content entered the warm tag phase, when the span between the last access time and the current time node is greater than 60 days, and when the number of accesses in the last 30 days is less than 5 times, the data tag of the stored content is updated to a cold tag when the above three situations occur; Among them, the frozen tag identification method refers to that when 90 days have passed since the evidence content entered the cold tag stage, the data tag of the evidence content is updated to a frozen tag.

7. The method for implementing the differentiated storage of hot and cold data in blockchain according to any one of claims 1 to 6, characterized in that: The method for changing the storage space of the evidence content is any one of the hot tag method, the warm tag method, the cold tag method, and the frozen tag method: The hot tag method means that when the data tag of the stored content is the hot tag, the block volume in the storage space of the stored content reaches 10MB, triggering block splitting, automatically updating the unified index and initiating the update of the data tag of the stored content on the chain, and updating and optimizing the block position to achieve the purpose of storage space change; The warm tag method means that when the data tag of the stored content is a warm tag, the block size in the storage space of the stored content is less than 2MB, triggering block merging, automatically updating the unified index and initiating the data tag update of the stored content on the chain, and updating and optimizing the block position to achieve the purpose of storage space change; The cold tag method means that when the data tag of the evidence content is a cold tag, the block volume in the storage space of the evidence content is less than 2MB, triggering block merging, automatically updating the unified index and initiating the data tag update of the evidence content on the chain, while updating and optimizing the block position, starting cross-chain migration, migrating the updated evidence content to the subchain for storage, clearing the original evidence content on the main chain, and updating the unified index to achieve the purpose of storage space change; The frozen tag method means that when the data tag of the evidence content is a frozen tag, the block volume in the storage space of the evidence content is less than 2MB, triggering block merging, automatically updating the unified index and initiating the data tag update of the on-chain evidence content, while updating and optimizing the block position, and then starting the cross-chain migration, migrating the evidence content to the sub-chain for storage, clearing the original evidence content of the main chain, and updating the unified index to achieve the purpose of storage space change.

8. A system for implementing differentiated storage of hot and cold blockchain data, characterized in that: Includes the following modules: Unified index module: On the blockchain platform, a unified index is established based on the stored content; Update data type label module: automatically update the data label of the stored content according to the record of the stored content in the unified index; Evidence data migration module: According to the data tag of the updated evidence content, the storage space of the evidence content is changed on the main chain and the sub-chain, and the storage space change is recorded in the unified index.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed, the steps of the method according to any one of claims 1 to 7 are implemented.

10. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the program, the steps of the method according to any one of claims 1 to 7 are implemented.

Citation Information

Cited By

  • Block chain-based enterprise data asset management method and system

    CN120655162A

  • Block chain evidence tracing method based on ocean carbon sink big data driving

    CN120746607A

  • A Blockchain-Based Evidence Storage and Traceability Method Driven by Big Data on Marine Carbon Sequestration

    CN120746607B