CN114006906B - Method for reducing memory consumption by optimizing node communication - Google Patents

Method for reducing memory consumption by optimizing node communication Download PDF

Info

Publication number
CN114006906B
CN114006906B CN202011317695.8A CN202011317695A CN114006906B CN 114006906 B CN114006906 B CN 114006906B CN 202011317695 A CN202011317695 A CN 202011317695A CN 114006906 B CN114006906 B CN 114006906B
Authority
CN
China
Prior art keywords
nodes
memory
communication
blockchain
consumption
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202011317695.8A
Other languages
Chinese (zh)
Other versions
CN114006906A (en
Inventor
阮安邦
果霖
魏明
陈旭明
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Octa Innovations Information Technology Co Ltd
Original Assignee
Beijing Octa Innovations Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Octa Innovations Information Technology Co Ltd filed Critical Beijing Octa Innovations Information Technology Co Ltd
Priority to CN202011317695.8A priority Critical patent/CN114006906B/en
Publication of CN114006906A publication Critical patent/CN114006906A/en
Application granted granted Critical
Publication of CN114006906B publication Critical patent/CN114006906B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1001Protocols in which an application is distributed across nodes in the network for accessing one among a plurality of replicated servers
    • H04L67/1031Controlling of the operation of servers by a load balancer, e.g. adding or removing servers that serve requests
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/06Notations for structuring of protocol data, e.g. abstract syntax notation one [ASN.1]

Abstract

The invention relates to the technical field of block chains, and discloses a method for reducing memory consumption by optimizing node communication, which completes the reduction of memory consumption by eliminating invalid nodes in communication objects and data communication, and comprises the following steps: the first step: and (3) establishing a memory: establishing a new memory in the block chain, wherein the new memory is used for buffering the communicated objects and data, and the second step is as follows: and reducing invalid nodes in the communication object. According to the method for reducing the memory consumption by optimizing the node communication, the invalid nodes in the communication object are maintained and detected in the address book mode, so that the memory consumption is greatly reduced, meanwhile, the address book also deletes the part which cannot be communicated on the communication object, the memory space is saved, meanwhile, some new communication nodes are supplemented to enter the blockchain, positions are provided for subsequent writing, and the utilization rate of the memory is improved under the condition that the memory consumption is continuously reduced, and the use of people to the blockchain is ensured.

Description

Method for reducing memory consumption by optimizing node communication
Technical Field
The invention relates to the technical field of blockchain, in particular to a method for reducing memory consumption by optimizing node communication.
Background
Blockchains are a term of art in information technology. Essentially, the system is a shared database, data or information stored in the shared database has the characteristics of 'non-falsifiability', 'whole trace', 'traceability', 'disclosure transparency', 'collective maintenance', and the like, based on the characteristics, a solid 'trust' foundation is laid by a blockchain technology, a reliable 'cooperation' mechanism is created, the system has wide application prospect, and the characteristics ensure 'honest' and 'transparency' of the blockchain and lay a foundation for creating trust for the blockchain. The application scene with rich blockchain is basically based on the blockchain, so that the problem of information asymmetry can be solved, and collaborative trust and consistent actions among a plurality of subjects are realized.
Memory is the core of the blockchain, which is a breakthrough computer programming language that is built in a critical manner. Because people depend on the use of the blockchain, some invalid and long-term non-communication nodes are continuously stored in the blockchain, so that the internal core memory of the blockchain is continuously accumulated, the internal memory is continuously consumed, the internal memory resources in some good blockchain nodes are occupied and cannot be effectively used, and the invalid and long-term non-communication nodes are removed without corresponding methods in the existing blockchain, so that a certain waste of the internal memory resources is caused
Disclosure of Invention
The invention provides a method for reducing memory consumption by optimizing node communication, which has the advantages of removing invalid and long-term unable communication nodes in a blockchain memory and improving the utilization rate of the blockchain memory, and solves the problems in the background technology.
The invention provides the following technical scheme: a method for reducing memory consumption by optimizing node communication includes the steps of:
the first step: establishing a memory
A new memory is created in the blockchain for buffering the communicated objects and data.
And a second step of: the method for reducing invalid nodes in the communication object comprises the following three steps of
1. The communication object is regularly maintained and detected in an address book mode, and the node in the communication object is maintained and detected in the survival rate condition, so that the node which cannot communicate in the communication object is found.
2. The address book maintenance and detection find some nodes which cannot communicate for a long time, so that the address book deletes the nodes which cannot communicate for a long time, and the consumption of memory is reduced.
3. After deleting the nodes which cannot be communicated for a long time, the address book supplements some nodes for supplementing the positions of the nodes which cannot be communicated for a long time, so that new nodes can be used in the subsequent use.
And a third step of: the method for solving the data communication is divided into the following three steps
1. By applying a reasonable data structure, the internal mass storage and analysis of the data communication are completed, invalid nodes in the data communication are removed and placed, the valid nodes are arranged in a concentrated mode, and the value and the use space of the blockchain data are improved.
2. By adopting a reasonable coding mode, new data communication is added to the blockchain, so that the new data communication nodes are subjected to threshold setting in the coding mode, the nodes added into the blockchain have certain value, and the nodes without value are not allowed to be added into the blockchain, so that the memory consumption in the blockchain is slowed down.
3. The network data is encapsulated by the frame with a compact structure, the data is divided into recoverable blocks by the frame, and whether the blocks are damaged or not can be easily checked, so that nodes in the blocks are checked, nodes in the damaged blocks are removed, memory loss in a block chain is reduced, and the utilization rate of the memory is improved.
Preferably, the nodes which cannot be communicated in the communication object are effectively removed in the address book mode, so that some new nodes are stored, subsequent use of people is guaranteed, consumption of memory is reduced, and the memory is utilized to the greatest extent.
Preferably, a reasonable data structure is used in the data communication to carry out systematic planning data communication, centralized unified normalization of effective communication nodes is ensured by means of big data in the data structure, and invalid communication nodes are put aside and deleted, so that consumption of memory is reduced.
Preferably, the nodes which cannot be communicated in the communication object are effectively removed in the address book mode, so that some new nodes are stored, subsequent use of people is guaranteed, consumption of memory is reduced, and the memory is utilized to the greatest extent.
Preferably, a reasonable data structure is used in the data communication to carry out systematic planning data communication, centralized unified normalization of effective communication nodes is ensured by means of big data in the data structure, and invalid communication nodes are put aside and deleted, so that consumption of memory is reduced.
Preferably, the coding mode sets a certain threshold for the communication node written into the blockchain, and when the certain threshold is reached, the communication node can be written into the blockchain, so that the writing of some communication nodes without value into the blockchain is avoided, the communication nodes placed in the memory are ensured to have certain significance, and the consumption of the memory is reduced.
Preferably, the compact frame is mainly used for checking whether the block chain is damaged, that is, whether invalid communication nodes exist in the block chain are judged in a frame form and then rejected, so that the consumption of the memory is further reduced.
The invention has the following beneficial effects:
1. according to the method for reducing the memory consumption by optimizing the node communication, the invalid nodes in the communication object are maintained and detected in the address book, so that the memory consumption is greatly reduced, meanwhile, the address book also deletes the part which cannot be communicated on the communication object, the memory space is saved, meanwhile, some new communication nodes are supplemented to enter the blockchain, the position is provided for subsequent writing, the utilization rate of the memory is improved under the condition that the memory consumption is continuously reduced, the use of the blockchain by people is ensured, only the surviving nodes exist in the memory, the blockchain can be utilized to the maximum extent, the consumption of the memory in the blockchain is reduced, and meanwhile, the blockchain memory is utilized to the maximum benefit.
2. According to the method for reducing the memory consumption by optimizing the node communication, the reasonable data structure, the coding mode and the frame with the compact structure are used for packaging network data, so that the data communication nodes are effectively detected, a certain threshold is set at the same time, the data communication of a worthless picture in the data communication is reduced to a certain extent, meanwhile, when a new communication node is written in, the threshold to a certain extent is needed, the worthless communication node cannot be written in a blockchain, the communication nodes in the blockchain memory have a certain degree of value, the memory consumption is reduced to a certain extent, the communication nodes in the memory have the utilization value for people, the memory environment of the nodes is optimized, the usability of the blockchain core memory is guaranteed, and more convenient use of the blockchain memory can be provided for people.
Drawings
FIG. 1 is a schematic flow chart of the method of the invention.
Detailed Description
The following description of the embodiments of the present invention will be made clearly and completely with reference to the accompanying drawings, in which it is apparent that the embodiments described are only some embodiments of the present invention, but not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
Referring to fig. 1, a method for reducing memory consumption by optimizing node communication includes the steps of:
the first step: establishing a memory
A new memory is created in the blockchain for buffering the communicated objects and data.
And a second step of: the method for reducing invalid nodes in the communication object comprises the following three steps of
1. The communication object is regularly maintained and detected in an address book mode, and the node in the communication object is maintained and detected in the survival rate condition, so that the node which cannot be communicated in the communication object is found, the space of a memory is saved, and more useful nodes can be stored.
2. The address book maintains and detects nodes which cannot be communicated for a long time, so that the address book deletes the nodes which cannot be communicated for a long time, and the consumption of memory is reduced, so that the memory can store more nodes.
3. After deleting the nodes which cannot be communicated for a long time, the address book supplements some nodes for supplementing the positions of the nodes which cannot be communicated for a long time, so that new nodes can have memory for use in the subsequent use.
And a third step of: the method for solving the data communication is divided into the following three steps
1. By applying a reasonable data structure, the internal mass storage and analysis of the data communication are completed, invalid nodes in the data communication are removed and placed, the valid nodes are arranged in a concentrated mode, and the value and the use space of the blockchain data are improved.
2. By adopting a reasonable coding mode, new data communication is added to the blockchain, so that the new data communication nodes are subjected to threshold setting in the coding mode, the nodes added into the blockchain have certain value, and the nodes without value are not allowed to be added into the blockchain, so that the memory consumption in the blockchain is slowed down.
3. The network data is encapsulated by the frame with a compact structure, the data is divided into recoverable blocks by the frame, and whether the blocks are damaged or not can be easily checked, so that nodes in the blocks are checked, nodes in the damaged blocks are removed, memory loss in a block chain is reduced, and the utilization rate of the memory is improved.
The method comprises the steps of selecting nodes which cannot be communicated from the communication object in an address book mode, storing a plurality of new nodes, guaranteeing subsequent use of people, slowing down consumption of memory, utilizing the memory to the greatest extent, enabling a user to be in the effective memory, and storing more useful nodes in the memory.
The method comprises the steps of carrying out systematic planning data communication by using a reasonable data structure in data communication, ensuring centralized unified normalization of effective communication nodes in a data structure in a large data mode, and laying aside and deleting invalid communication nodes so as to slow down consumption of memory.
The coding mode is to set a certain threshold for the communication nodes written into the blockchain, and the communication nodes can be written into the blockchain only when the certain threshold is reached, so that the situation that some communication nodes without value are written into the blockchain is avoided, the communication nodes placed in the memory are ensured to have certain significance, and the consumption of the memory is reduced.
The frame with compact structure is mainly used for checking whether the block chain is damaged or not, namely invalid communication nodes in the block chain are judged in a frame mode, and then the frames are removed, so that the consumption of the memory is further reduced, more useful nodes can be stored in the memory, and the utilization rate of the memory is improved.
The method comprises the steps of maintaining and detecting invalid nodes in a communication object in an address book mode, greatly reducing consumption of a memory, deleting a part which cannot be communicated on the communication object in the address book, saving space of the memory, supplementing new communication nodes into a blockchain, providing positions for subsequent writing, improving utilization rate of the memory under the condition of continuously reducing the consumption of the memory, ensuring that people use the blockchain, enabling only surviving nodes exist in the memory, and enabling the blockchain to be utilized to the maximum.
The method comprises the steps of carrying out effective detection on data communication nodes by using a reasonable data structure, a coding mode and a frame with a compact structure to encapsulate network data, setting a certain threshold at the same time, reducing the data communication of a worthless picture in the data communication to a certain extent, simultaneously writing new communication nodes, needing a certain threshold, ensuring that the worthless communication nodes cannot be written into a blockchain, ensuring that the communication nodes in a blockchain memory have a certain value, reducing the memory consumption to a certain extent, and ensuring that the communication nodes in the memory have a utilization value for people, thereby optimizing the memory environment of the nodes.
It is noted that relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Moreover, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus.
Although embodiments of the present invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made therein without departing from the principles and spirit of the invention, the scope of which is defined in the appended claims and their equivalents.

Claims (5)

1. A method for reducing memory consumption by optimizing node communication includes the steps of:
the first step: establishing a memory
Establishing a new memory in the block chain, wherein the new memory is used for buffering the communicated objects and data;
and a second step of: the method for reducing invalid nodes in the communication object comprises the following three steps of
1. The method comprises the steps of regularly maintaining and detecting a communication object in an address book mode, and maintaining and detecting the survival rate of nodes in the communication object, so that nodes which cannot communicate in the communication object are found;
2. the address book maintenance and detection find some nodes which cannot be communicated for a long time, so that the address book deletes the nodes which cannot be communicated for a long time, and the consumption of memory is reduced;
3. after deleting the nodes which cannot be communicated for a long time, the address book supplements some nodes for supplementing the positions of the nodes which cannot be communicated for a long time, so that new nodes can be used in the subsequent use;
and a third step of: the method for solving the data communication is divided into the following three steps
1. By applying a reasonable data structure, the internal mass storage and analysis of the data communication are completed, so that invalid nodes in the data communication are removed and shelved, the valid nodes are arranged in a concentrated mode, and the value and the use space of the blockchain data are improved;
2. adding new data communication on the blockchain is completed by applying a reasonable coding mode, so that the new data communication nodes are subjected to thresholding by the coding mode, so that the nodes added into the blockchain have certain value, and the nodes without value are not allowed to be added into the blockchain, thereby reducing the memory consumption in the blockchain;
3. the network data is encapsulated by the frame with a compact structure, the data is divided into recoverable blocks by the frame, and whether the blocks are damaged or not can be easily checked, so that nodes in the blocks are checked, nodes in the damaged blocks are removed, memory loss in a block chain is reduced, and the utilization rate of the memory is improved.
2. A method for reducing memory consumption by optimizing node communication as defined in claim 1, wherein: the nodes which cannot be communicated in the communication object are effectively removed in the address book mode, so that some new nodes are stored, the subsequent use of people is guaranteed, the consumption of the memory is reduced, and the memory is utilized to the greatest extent.
3. A method for reducing memory consumption by optimizing node communication as defined in claim 1, wherein: and in the data communication, a reasonable data structure is used for systematic planning data communication, centralized unified normalization of effective communication nodes is ensured by a large data mode in the data structure, and invalid communication nodes are put aside and deleted, so that the consumption of memory is reduced.
4. A method for reducing memory consumption by optimizing node communication as defined in claim 1, wherein: the coding mode is to set a certain threshold for the communication nodes written into the blockchain, and the communication nodes can be written into the blockchain only when the certain threshold is reached, so that the situation that some communication nodes without value are written into the blockchain is avoided, the communication nodes placed in the memory are ensured to have certain significance, and the consumption of the memory is reduced.
5. A method for reducing memory consumption by optimizing node communication as defined in claim 1, wherein: the compact frame is mainly used for checking whether the block chain is damaged or not, namely invalid communication nodes in the block chain are judged in a frame mode and then are removed, so that the consumption of the memory is further reduced.
CN202011317695.8A 2020-11-23 2020-11-23 Method for reducing memory consumption by optimizing node communication Active CN114006906B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011317695.8A CN114006906B (en) 2020-11-23 2020-11-23 Method for reducing memory consumption by optimizing node communication

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011317695.8A CN114006906B (en) 2020-11-23 2020-11-23 Method for reducing memory consumption by optimizing node communication

Publications (2)

Publication Number Publication Date
CN114006906A CN114006906A (en) 2022-02-01
CN114006906B true CN114006906B (en) 2023-11-07

Family

ID=79920682

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011317695.8A Active CN114006906B (en) 2020-11-23 2020-11-23 Method for reducing memory consumption by optimizing node communication

Country Status (1)

Country Link
CN (1) CN114006906B (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109582735A (en) * 2018-10-26 2019-04-05 黄淮学院 A kind of block chain blocks of knowledge storage system
CN110019043A (en) * 2017-12-18 2019-07-16 厦门本能管家科技有限公司 A kind of block chain date storage method
CN110046894A (en) * 2019-04-19 2019-07-23 电子科技大学 A kind of restructural block chain method for building up of grouping based on correcting and eleting codes
CN110430087A (en) * 2019-09-16 2019-11-08 上海保险交易所股份有限公司 The architecture design and realization of block chain heat upgrading
EP3709568A1 (en) * 2019-03-14 2020-09-16 Nokia Technologies Oy Deleting user data from a blockchain

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11151261B2 (en) * 2019-04-03 2021-10-19 Cisco Technology, Inc. Blockchain system with severable data and cryptographic proof

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110019043A (en) * 2017-12-18 2019-07-16 厦门本能管家科技有限公司 A kind of block chain date storage method
CN109582735A (en) * 2018-10-26 2019-04-05 黄淮学院 A kind of block chain blocks of knowledge storage system
EP3709568A1 (en) * 2019-03-14 2020-09-16 Nokia Technologies Oy Deleting user data from a blockchain
CN110046894A (en) * 2019-04-19 2019-07-23 电子科技大学 A kind of restructural block chain method for building up of grouping based on correcting and eleting codes
CN110430087A (en) * 2019-09-16 2019-11-08 上海保险交易所股份有限公司 The architecture design and realization of block chain heat upgrading

Also Published As

Publication number Publication date
CN114006906A (en) 2022-02-01

Similar Documents

Publication Publication Date Title
CN104778222B (en) Media library based on USB storage device is established and update method
CN106682077A (en) Method for storing massive time series data on basis of Hadoop technologies
CN101446966A (en) Data storage method and system
CN103593257B (en) A kind of data back up method and device
CN103049393B (en) Memory headroom management method and device
ATE387665T1 (en) RESOURCE MANAGEMENT FOR DATA STORAGE SERVICES
CN103617007A (en) Method and system for achieving multilevel intelligent storage
CN110083306A (en) A kind of distributed objects storage system and storage method
CN103761262A (en) Repetition log control method based on syslogd
CN103019956B (en) A kind of to data cached method of operating and device
CN111352589B (en) Distributed storage method, device, equipment and readable medium
CN114006906B (en) Method for reducing memory consumption by optimizing node communication
CN103207866A (en) File storing method and system based on partitioning strategies
CN109189724B (en) Method and device for improving audio and video data storage efficiency of video monitoring system
CN110750372A (en) Log system based on shared memory and log management method
CN102685222B (en) A kind of cloud SRM device for electric power system
CN107329695B (en) Distributed storage memory management method, system and computer storage medium
CN110007905A (en) A kind of generation method and system of the software development scheme based on big data
CN103164532B (en) The classification piecemeal abstracting method of grid model data and system
CN100585597C (en) File organization method
CN109635161B (en) Cross-domain allopatric collaborative design method in mass data environment
CN111124313A (en) Data reading and writing method and device for power acquisition terminal and electronic equipment
CN111427867B (en) Model persistence method based on hybrid storage
CN102855255A (en) Content management and publish method and system
CN105138278A (en) Method for storing network messages of intelligent substation in bare disk

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant