CN109241365B - Block chain system construction method, medium, computer equipment and block chain system - Google Patents

Block chain system construction method, medium, computer equipment and block chain system Download PDF

Info

Publication number
CN109241365B
CN109241365B CN201810969311.7A CN201810969311A CN109241365B CN 109241365 B CN109241365 B CN 109241365B CN 201810969311 A CN201810969311 A CN 201810969311A CN 109241365 B CN109241365 B CN 109241365B
Authority
CN
China
Prior art keywords
task
node
block
request
production
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
CN201810969311.7A
Other languages
Chinese (zh)
Other versions
CN109241365A (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.)
Ke'an Xiamen Technology Co ltd
Original Assignee
Tailian Xiamen 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 Tailian Xiamen Technology Co ltd filed Critical Tailian Xiamen Technology Co ltd
Priority to CN201810969311.7A priority Critical patent/CN109241365B/en
Publication of CN109241365A publication Critical patent/CN109241365A/en
Application granted granted Critical
Publication of CN109241365B publication Critical patent/CN109241365B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G07CHECKING-DEVICES
    • G07CTIME OR ATTENDANCE REGISTERS; REGISTERING OR INDICATING THE WORKING OF MACHINES; GENERATING RANDOM NUMBERS; VOTING OR LOTTERY APPARATUS; ARRANGEMENTS, SYSTEMS OR APPARATUS FOR CHECKING NOT PROVIDED FOR ELSEWHERE
    • G07C13/00Voting apparatus

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The invention provides a block chain system construction method, a medium, computer equipment and a block chain system, wherein the block chain system comprises a plurality of nodes, and each node is provided with a task operation table and a statistical information table; the method comprises the following steps: receiving a task request; after the project corresponding to the task request is confirmed, receiving the operation request so that the production node can operate and count the task of the project by inquiring the statistical information table according to the operation request, and discarding the operation request after finishing one operation request; judging whether the block production power time limit of the production node is reached; if the block production authority time limit of the production node is reached, the block is packed into a block after the accumulation operation is executed, and the whole network broadcasting is carried out. Therefore, the operation and the statistics of the key information in the operation request are realized, and the operation request is discarded after the operation and the statistics, so that the storage load of the nodes in the block chain system is reduced, and the normal operation of the nodes in the block chain system is ensured.

Description

Block chain system construction method, medium, computer equipment and block chain system
Technical Field
The present invention relates to the field of blockchain technologies, and in particular, to a method, a medium, a computer device, and a blockchain system for constructing a blockchain system.
Background
The blockchain is a scheme for maintaining a reliable database in a decentralized and distrust manner, and is widely applied due to the characteristics of decentralized and distrust and difficulty in data tampering.
In the conventional blockchain system, in the process of storing operations (e.g., voting, chess score statistics, etc.), all process information of the operations is stored, which results in a waste of a large amount of storage resources, and particularly when the system in the blockchain is a mobile terminal, the system is very likely to cause an excessive storage burden on nodes and to break down.
Disclosure of Invention
The present invention is directed to solving, at least to some extent, one of the technical problems in the art described above. Therefore, an object of the present invention is to provide a method for constructing a blockchain system, which can implement operation and statistics on key information in an operation request, and discard the operation request after the operation and statistics, so as to reduce the storage load of nodes in the blockchain system and ensure normal operation of the nodes in the blockchain system.
A second object of the invention is to propose a computer-readable storage medium.
A third object of the invention is to propose a computer device.
A fourth objective of the present invention is to provide a block chain system.
In order to achieve the above object, a first embodiment of the present invention provides a method for constructing a blockchain system, where the blockchain system includes a plurality of nodes, and each node is configured with a task operation table and a statistical information table, where the task operation table is configured in a manner that no operation is recorded, and the method includes the following steps: receiving a task request initiated by any node, so that a production node in the block chain system can produce a block according to the task request to carry out full-network synchronization; after the project corresponding to the task request is confirmed, receiving an operation request initiated by each node for the project through the task operation table, so that the production node can operate and count the task of the project by inquiring the statistical information table according to the operation request, and discarding the operation request after each operation request is completed; judging whether the block production power time limit of the production node is reached; and if the block production right time limit of the production node is reached, accumulating the statistical results by the production node, packaging the statistical results into blocks, and broadcasting the blocks in the whole network so as to synchronize the statistical result information at each node.
According to the construction method of the blockchain system, the blockchain system comprises a plurality of nodes, each node is configured with a task operation table and a statistical information table, wherein the task operation table is configured in a mode of not recording operation, and the method comprises the following steps: firstly, receiving a task request initiated by any node, so that a production node in a block chain system produces a block according to the task request to carry out full-network synchronization; then, after the project corresponding to the task request is confirmed, receiving an operation request initiated by each node aiming at the project through a task operation table, so that the production node can operate and count the task of the project by inquiring a statistical information table according to the operation request, and discarding the operation request after finishing one operation request; then, judging whether the block production power time limit of the production node is reached; then, if the block production right time limit of the production node is reached, the statistical results are packed into blocks after the production node performs accumulation operation on the statistical results, and the whole network broadcasting is carried out, so that the statistical result information is synchronized at each node; therefore, the operation and the statistics of the key information in the operation request are realized, and the operation request is discarded after the operation and the statistics, so that the storage load of the nodes in the block chain system is reduced, and the normal operation of the nodes in the block chain system is ensured.
In addition, the block chain system construction method proposed according to the above embodiment of the present invention may further have the following additional technical features:
optionally, when the blockchain system is a voting blockchain system, the task operation table includes IDs of voted objects and voting item task IDs, and the statistics table includes statistics sources, statistics objects, and statistics types.
Optionally, the statistical information table represents an operation of performing cumulative statistics on the selected objects in the task operation table.
Optionally, when the production node queries the statistical information table according to the operation request, if a content item for performing cumulative statistics on the elected object exists in the statistical information table, determining whether the content item of the voting item task exists in the election task cumulative table by looking up an election task cumulative table in a local cache of the node, and when the content item of the voting item task exists in the election task cumulative table, determining whether a sub-item of the elected object exists in the content item of the voting item task, wherein if the content item exists, adding 1 to a statistical value of the elected object; and if the statistical value of the elected object does not exist, creating a sub item of the elected object, and setting the statistical value of the elected object to be 1.
Optionally, the task operation table and the statistics table are loaded through an initial node of the blockchain system, so that after an ancestry block is created by the initial node, other nodes in the blockchain system synchronize the ancestry block to synchronize the task operation table and the statistics table.
In order to achieve the above object, a second aspect of the present invention provides a computer-readable storage medium, on which a building program of a blockchain system is stored, and the building program of the blockchain system, when executed by a processor, implements the building method of the blockchain system.
In order to achieve the above object, a third embodiment of the present invention provides a computer device, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, and when the processor executes the computer program, the computer device implements the above method for constructing the block chain system.
In order to achieve the above object, a fourth aspect of the present invention provides a blockchain system, including a plurality of nodes, each node being configured with a task operation table and a statistical information table, wherein the task operation table is configured in a manner that no operation is recorded, each node further including a memory, a processor, and a computer program stored in the memory and executable on the processor, and the processor, when executing the computer program, implements the above construction method of blockchain system.
Drawings
FIG. 1 is a flow chart illustrating a method for constructing a blockchain system according to an embodiment of the present invention;
fig. 2 is a flow chart illustrating a method for constructing a blockchain system according to another embodiment of the invention.
Detailed Description
Reference will now be made in detail to embodiments of the present invention, examples of which are illustrated in the accompanying drawings, wherein like or similar reference numerals refer to the same or similar elements or elements having the same or similar function throughout. The embodiments described below with reference to the drawings are illustrative and intended to be illustrative of the invention and are not to be construed as limiting the invention.
In the existing block chain system, in the process of storing operations (such as voting, chess score statistics, etc.), all process information of the operations is stored, which results in waste of a large amount of storage resources; the construction method of the block chain system provided by the embodiment of the invention comprises a plurality of nodes, wherein each node is configured with a task operation table and a statistical information table, the task operation table is configured in a mode of not recording operation, and the method comprises the following steps: firstly, receiving a task request initiated by any node, so that a production node in a block chain system produces a block according to the task request to carry out full-network synchronization; then, after the project corresponding to the task request is confirmed, receiving an operation request initiated by each node aiming at the project through a task operation table, so that the production node can operate and count the task of the project by inquiring a statistical information table according to the operation request, and discarding the operation request after finishing one operation request; then, judging whether the block production power time limit of the production node is reached; then, if the block production right time limit of the production node is reached, the statistical results are packed into blocks after the production node performs accumulation operation on the statistical results, and the whole network broadcasting is carried out, so that the statistical result information is synchronized at each node; therefore, the operation and the statistics of the key information in the operation request are realized, and the operation request is discarded after the operation and the statistics, so that the storage load of the nodes in the block chain system is reduced, and the normal operation of the nodes in the block chain system is ensured.
In order to better understand the above technical solutions, exemplary embodiments of the present invention will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the invention are shown in the drawings, it should be understood that the invention can be embodied in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the invention to those skilled in the art.
In order to better understand the technical solution, the technical solution will be described in detail with reference to the drawings and the specific embodiments.
Fig. 1 is a flowchart illustrating a method for constructing a blockchain system according to an embodiment of the present invention, where the blockchain system includes a plurality of nodes, each node is configured with a task operation table and a statistical information table, and the task operation table is configured in a way that no operation is recorded, as shown in fig. 1, the method for constructing the blockchain system includes the following steps:
s101, receiving a task request initiated by any node, so that a production node in the blockchain system produces a block according to the task request to perform whole network synchronization.
That is, a task request initiated by any node in the blockchain system is received, so that a production node in the blockchain system produces a block according to the task request for network-wide synchronization.
The method includes that a production node produces blocks according to task requests, for example, after receiving a task request, the production node caches the task request, and packs the task requests of a previous block time line and a current time after a time difference between the previous block time line and the current time reaches a preset time to form a block; or after receiving the task requests, the production node caches the task requests, and packs the task requests of the previous block time line and the current time after the number of the task requests of the previous block time line and the current time reaches a preset number to form a block.
The task request mode can be various, for example, a voting request, a block chain competitive project win-loss statistical request, a transaction frequency statistical request, and the like; therefore, the form of the task request is not limited herein.
S102, after the project corresponding to the task request is confirmed, receiving an operation request initiated by each node aiming at the project through the task operation table, so that the production node can operate and count the task of the project by inquiring the statistical information table according to the operation request, and discarding the operation request after finishing one operation request.
That is, after an item corresponding to a task request is confirmed by the blockchain system, the nodes in the blockchain are allowed to perform an operation corresponding to the item, and an operation request initiated by each node in the blockchain for the item through the task operation table is received.
For example, after the production nodes pack the blocks and broadcast, acquiring the number of online nodes in the current block chain system, counting the number of nodes which synchronize the blocks after the nodes in the block chain synchronize the blocks, and judging whether the ratio of the counted number of nodes which synchronize the blocks to the number of online nodes in the current block chain system reaches a preset threshold value, if so, judging that the item corresponding to the task request is confirmed; or after the block is packaged and broadcasted by the production node, counting the number of the nodes which synchronize the block, and judging whether the ratio of the number of the nodes which synchronize the block to the total number of the nodes in the block chain system reaches a preset threshold value, if so, judging that the project corresponding to the task request is confirmed.
It should be noted that the task operation table configures the content specified in the assigned configuration task operation table in a manner of not recording operations, as the content that needs to be discarded after the operation request is operated and counted by the production node.
As an example, when the blockchain system is a voting blockchain system, the task operation table includes the ID of the voted object and the voting item task ID, and the statistics table includes the statistics source, the statistics object, and the statistics type. Taking a practical case as an example, in the voting operation, defining the content format corresponding to the operation request in the task operation table as select (pid, oid); wherein select is a function name, oid indicates an ID corresponding to the elected object, and pid indicates an ID corresponding to the voting project task; then the operation request select (pid, oid) is discarded after the production node operates and counts the operation requests according to the task operation table.
Receiving an operation request initiated by each node for the item through the task operation table means that each node in the block chain searches an operation format associated with the item corresponding to the task request in the task operation table, and initiates the operation request to the block chain system according to the operation format.
As an example, after an item corresponding to a task request is confirmed by the blockchain system, the user node finds that an operation format associated with the item corresponding to the task request is select (pid, oid) through the task operation table, and then the user node initiates an operation request to the blockchain system according to the operation format; where select is the function name, oid indicates the ID corresponding to the object being voted, and pid indicates the ID corresponding to the voting project task.
For example, after receiving the operation request, the production node establishes a project statistic item of the project corresponding to the operation request in the statistic information table according to the operation request, and operates and counts the project statistic item of the corresponding project according to the operation request.
As an example, in a voting operation, a user node sends an operation request select (pid, oid), after receiving the operation request, a production node establishes a project statistic item corresponding to the pid in a statistic information table according to the pid in the operation request, and establishes oid corresponding sub-items in the project statistic item corresponding to the pid, so as to perform respective statistics on election objects corresponding to different projects according to the operation request; where select is the function name, oid indicates the ID corresponding to the object being voted, and pid indicates the ID corresponding to the voting project task.
S103, judging whether the block production authority time limit of the production node is reached.
For example, whether the time difference from the previous block time line to the current time reaches a preset time threshold value is judged, if yes, the block production right time limit of the production node is judged to have reached, or whether the number of the operation requests from the previous block time line to the current time reaches a preset number predicted value is judged, and if yes, the block production right time limit of the production node is judged to have reached.
S104, if the block production right time limit of the production node is reached, the statistical results are packed into blocks after the production node performs accumulation operation on the statistical results, and the whole network broadcasting is carried out so as to synchronize the statistical result information at each node.
That is, when the block production authority limit of the production node is reached, the statistical result is accumulated by the production node and packed into a block, and the block is broadcast all over the network so that each node in the block chain synchronizes the statistical result information.
In summary, according to the method for constructing a blockchain system in an embodiment of the present invention, the blockchain system includes a plurality of nodes, each node is configured with a task operation table and a statistical information table, wherein the task operation table is configured in a way of not recording operations, and the method includes the following steps: firstly, receiving a task request initiated by any node, so that a production node in a block chain system produces a block according to the task request to carry out full-network synchronization; then, after the project corresponding to the task request is confirmed, receiving an operation request initiated by each node aiming at the project through a task operation table, so that the production node can operate and count the task of the project by inquiring a statistical information table according to the operation request, and discarding the operation request after finishing one operation request; then, judging whether the block production power time limit of the production node is reached; then, if the block production right time limit of the production node is reached, the statistical results are packed into blocks after the production node performs accumulation operation on the statistical results, and the whole network broadcasting is carried out, so that the statistical result information is synchronized at each node; therefore, the operation and the statistics of the key information in the operation request are realized, and the operation request is discarded after the operation and the statistics, so that the storage load of the nodes in the block chain system is reduced, and the normal operation of the nodes in the block chain system is ensured.
Fig. 2 is a flow chart illustrating a method for constructing a blockchain system according to another embodiment of the present invention, as shown in fig. 2, the method for constructing a blockchain system includes the following steps:
s201, a task operation table and a statistical information table are configured for each node in the block chain system.
The task operation table is configured in a mode of not recording operation, and comprises the ID of the selected object and the ID of the voting project task; the statistical information table comprises statistical sources, statistical objects and statistical types, and the statistical information table is expressed as the operation of performing accumulation statistics on selected objects in the task operation table; that is, the statistical information table is used for performing cumulative statistics on the selected objects in the task operation table.
S202, the task operation table and the statistical information table are loaded through the initial node of the blockchain system, so that after the created block is created at the initial node, other nodes in the blockchain system synchronize the task operation table and the statistical information table through synchronizing the created block.
That is, the initial node of the blockchain system loads the task operation table and the statistics table, so that after the initial node creates the created block, other nodes connected to the blockchain system can synchronize the task operation table and the statistics table by synchronizing the created block, and perform configuration synchronization of the task operation table and the statistics table.
S203, receiving a task request initiated by any node, so that a production node in the blockchain system produces a block according to the task request to perform whole network synchronization.
And S204, after the project corresponding to the task request is confirmed, receiving an operation request initiated by each node aiming at the project through the task operation table.
S205, the production node inquires the statistical information table according to the operation request, and judges whether the statistical information table has the content item which is subjected to accumulation statistics aiming at the elected object.
That is, after receiving the operation request, the production node queries the statistical information table according to the operation request, and determines whether the content item accumulated and counted for the elected object exists in the statistical information table, so as to determine whether the operation request is an operation requiring statistics.
S206, when the judgment result is yes, searching the election task accumulation table locally cached by the node to judge whether the content item of the voting item task exists in the election task accumulation table.
That is, after the production node determines that the operation request is an operation that needs to be counted, the election task accumulation table locally cached by the node is searched to determine whether the content item of the voting item task exists in the election task accumulation table.
And when the judgment result is negative, establishing a corresponding content item for the voting project task so as to count the voting project task.
The election task accumulation table of the local cache refers to an election task accumulation table for counting election tasks generated by a current block in the block production process by a production node, and is used for counting voting task items generated by the current block; and the voting task items are used as the basis for the subsequent production nodes to gather the voting task items.
S207, judging whether the content items of the voting project task have the sub-items of the elected objects or not when the judgment result is yes; if yes, go to step S208; if not, step S209 is executed.
That is, when the production node determines that the voting task accumulation table cached locally at the node has the content item of the voting task, it determines whether the content item of the voting task has the sub-item of the elected object according to the elected object included in the operation request.
And S208, adding 1 to the statistical value of the selected object.
S209, creating a sub item of the selected object, and setting the statistic value of the selected object to be 1.
S210, judging whether the block production power time limit of the production node is reached.
S211, if the block production right time limit of the production node is reached, the statistical results are packed into blocks after the production node performs accumulation operation on the statistical results, and the whole network broadcasting is carried out, so that the statistical result information is synchronized at each node.
The step of performing accumulation operation on the statistical result by the production node and then packaging the statistical result into a block refers to accumulating the election task accumulation table of the current local cache of the production node and the historical election task statistical information of the system to obtain complete statistical information and packaging the complete statistical information into the block.
As an example, the election task accumulation table (LT) is cached locally at the production node, and when the block production right time limit of the production node arrives, the production node acquires the system task table (T) in the block chain system; and initiating a cumulative (LT) operation to accumulate the statistic item in the LT into T so as to achieve complete statistics of the statistic result of the election task in the block chain.
In summary, according to the method for constructing a blockchain system in the embodiment of the present invention, first, a task operation table and a statistical information table are configured for each node in the blockchain system; then, loading the task operation table and the statistical information table through an initial node of the blockchain system, so that other nodes in the blockchain system synchronize the task operation table and the statistical information table through synchronizing the created blocks after the created blocks are created at the initial node; then, receiving a task request initiated by any node, so that a production node in the blockchain system produces a block according to the task request to perform full-network synchronization; then, after the project corresponding to the task request is confirmed, receiving an operation request initiated by each node aiming at the project through a task operation table; then, the production node inquires a statistical information table according to the operation request and judges whether a content item for performing accumulation statistics on the elected object exists in the statistical information table or not; then, when the judgment result is yes, searching an election task accumulation table locally cached by the node to judge whether the content item of the voting item task exists in the election task accumulation table or not; then, when the judgment result is yes, judging whether the sub item of the elected object exists in the content items of the voting project task; if yes, adding 1 to the statistical value of the selected object; if not, creating a sub item of the selected object, and setting the statistical value of the selected object as 1; then, judging whether the block production power time limit of the production node is reached; then, if the block production right time limit of the production node is reached, the statistical results are packed into blocks after the production node performs accumulation operation on the statistical results, and the whole network broadcasting is carried out so as to synchronize the statistical result information at each node; therefore, the operation and the statistics of the key information in the operation request are realized, and the operation request is discarded after the operation and the statistics, so that the storage load of the nodes in the block chain system is reduced, and the normal operation of the nodes in the block chain system is ensured.
In order to implement the above embodiments, an embodiment of the present invention provides a computer-readable storage medium, on which a building program of a blockchain system is stored, and the building program of the blockchain system, when executed by a processor, implements the building method of the blockchain system described above.
In order to implement the foregoing embodiments, an embodiment of the present invention provides a computer device, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, and when the processor executes the computer program, the computer device implements the above construction method of the block chain system.
In order to implement the foregoing embodiments, an embodiment of the present invention provides a blockchain system, which includes a plurality of nodes, each node being configured with a task operation table and a statistical information table, where the task operation table is configured in a manner that no operation is recorded, each node further including a memory, a processor, and a computer program stored in the memory and executable on the processor, and when the processor executes the computer program, the method for constructing the blockchain system described above is implemented.
It should be noted that the above description of the method for constructing the blockchain system in fig. 1 is also applicable to the computer-readable storage medium, the computer device and the blockchain system, and is not repeated herein.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, system, or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present invention is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
It should be noted that in the claims, any reference signs placed between parentheses shall not be construed as limiting the claim. The word "comprising" does not exclude the presence of elements or steps not listed in a claim. The word "a" or "an" preceding an element does not exclude the presence of a plurality of such elements. The invention may be implemented by means of hardware comprising several distinct elements, and by means of a suitably programmed computer. In the unit claims enumerating several means, several of these means may be embodied by one and the same item of hardware. The usage of the words first, second and third, etcetera do not indicate any ordering. These words may be interpreted as names.
While preferred embodiments of the present invention have been described, additional variations and modifications in those embodiments may occur to those skilled in the art once they learn of the basic inventive concepts. Therefore, it is intended that the appended claims be interpreted as including preferred embodiments and all such alterations and modifications as fall within the scope of the invention.
It will be apparent to those skilled in the art that various changes and modifications may be made in the present invention without departing from the spirit and scope of the invention. Thus, if such modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include such modifications and variations.
In the description of the present invention, it is to be understood that the terms "first", "second" and the like are used for descriptive purposes only and are not to be construed as indicating or implying relative importance or implying any number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature. In the description of the present invention, "a plurality" means two or more unless specifically defined otherwise.
In the present invention, unless otherwise expressly stated or limited, the terms "mounted," "connected," "secured," and the like are to be construed broadly and can, for example, be fixedly connected, detachably connected, or integrally formed; can be mechanically or electrically connected; either directly or indirectly through intervening media, either internally or in any other relationship. The specific meanings of the above terms in the present invention can be understood by those skilled in the art according to specific situations.
In the present invention, unless otherwise expressly stated or limited, the first feature "on" or "under" the second feature may be directly contacting the first and second features or indirectly contacting the first and second features through an intermediate. Also, a first feature "on," "over," and "above" a second feature may be directly or diagonally above the second feature, or may simply indicate that the first feature is at a higher level than the second feature. A first feature being "under," "below," and "beneath" a second feature may be directly under or obliquely under the first feature, or may simply mean that the first feature is at a lesser elevation than the second feature.
In the description herein, references to the description of the term "one embodiment," "some embodiments," "an example," "a specific example," or "some examples," etc., mean that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of the invention. In this specification, the schematic representations of the terms used above should not be understood to necessarily refer to the same embodiment or example. Furthermore, the particular features, structures, materials, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples. Furthermore, various embodiments or examples and features of different embodiments or examples described in this specification can be combined and combined by one skilled in the art without contradiction.
Although embodiments of the present invention have been shown and described above, it is understood that the above embodiments are exemplary and should not be construed as limiting the present invention, and that variations, modifications, substitutions and alterations can be made to the above embodiments by those of ordinary skill in the art within the scope of the present invention.

Claims (6)

1. A method for constructing a blockchain system, wherein the blockchain system comprises a production node and a plurality of nodes, each node is configured with a task operation table and a statistical information table, wherein the task operation table is configured in a way of not recording operations, and the task operation table is configured in a way of not recording operations, which means that contents specified in the task operation table are configured to be contents which need to be discarded after operation requests are operated and counted by the production node, the method comprises the following steps:
receiving a task request initiated by any node, so that a production node in the block chain system can produce a block according to the task request to carry out full-network synchronization;
after the project corresponding to the task request is confirmed, receiving an operation request initiated by each node for the project through the task operation table, so that the production node can operate and count the task of the project by inquiring the statistical information table according to the operation request, and discarding the operation request after each operation request is completed;
judging whether the block production power time limit of the production node is reached;
if the block production right time limit of the production node is reached, the statistical results are packed into blocks after the production node performs accumulation operation, and the whole network broadcasting is carried out so as to synchronize the statistical result information at each node;
when the blockchain system is a voting blockchain system, the task operation table comprises an ID of an elected object and a voting project task ID, and the statistical information table comprises a statistical source, a statistical object and a statistical type;
when the production node inquires the statistical information table according to the operation request, if the statistical information table has a content item for performing accumulation statistics on the elected object, judging whether the election task accumulation table has a content item of a voting item task by searching an election task accumulation table in a local cache of the node, and judging whether the content item of the voting item task has a sub-item of the elected object when the election task accumulation table has the content item of the voting item task, wherein,
if yes, adding 1 to the statistic value of the elected object;
and if the statistical value of the elected object does not exist, creating a sub item of the elected object, and setting the statistical value of the elected object to be 1.
2. The method of claim 1, wherein the statistics table represents operations for performing cumulative statistics on selected objects in the task operations table.
3. The method of any of claims 1-2, wherein the task operations table and statistics table are loaded by an initial node of the blockchain system, such that other nodes in the blockchain system synchronize the founder block to synchronize the task operations table and statistics table after the initial node creates the founder block.
4. A computer-readable storage medium, on which a building program of a blockchain system is stored, which when executed by a processor implements a building method of the blockchain system according to any one of claims 1 to 3.
5. A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor, when executing the computer program, implements the method of constructing a block chain system according to any one of claims 1 to 3.
6. A blockchain system comprising a plurality of nodes, each node being configured with a task operation table and a statistics table, wherein the task operation table is configured in a way that no operation is recorded, each node further comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the method of constructing a blockchain system according to any one of claims 1 to 3 when executing the computer program.
CN201810969311.7A 2018-08-23 2018-08-23 Block chain system construction method, medium, computer equipment and block chain system Active CN109241365B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810969311.7A CN109241365B (en) 2018-08-23 2018-08-23 Block chain system construction method, medium, computer equipment and block chain system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810969311.7A CN109241365B (en) 2018-08-23 2018-08-23 Block chain system construction method, medium, computer equipment and block chain system

Publications (2)

Publication Number Publication Date
CN109241365A CN109241365A (en) 2019-01-18
CN109241365B true CN109241365B (en) 2020-11-20

Family

ID=65069457

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810969311.7A Active CN109241365B (en) 2018-08-23 2018-08-23 Block chain system construction method, medium, computer equipment and block chain system

Country Status (1)

Country Link
CN (1) CN109241365B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110008665B (en) * 2019-03-05 2024-02-06 深圳前海微众银行股份有限公司 Authority control method and device for blockchain

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106406896A (en) * 2016-09-27 2017-02-15 北京天德科技有限公司 Block chain block-building method based on parallel PipeLine technology
CN106649838A (en) * 2016-12-29 2017-05-10 先锋支付有限公司 Data transmission method, block chain node and distributed database
CN108418622A (en) * 2018-02-11 2018-08-17 西安电子科技大学昆山创新研究院 A kind of unmanned aerial vehicle group body decision method based on block chain

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106406896A (en) * 2016-09-27 2017-02-15 北京天德科技有限公司 Block chain block-building method based on parallel PipeLine technology
CN106649838A (en) * 2016-12-29 2017-05-10 先锋支付有限公司 Data transmission method, block chain node and distributed database
CN108418622A (en) * 2018-02-11 2018-08-17 西安电子科技大学昆山创新研究院 A kind of unmanned aerial vehicle group body decision method based on block chain

Also Published As

Publication number Publication date
CN109241365A (en) 2019-01-18

Similar Documents

Publication Publication Date Title
CN107332876B (en) Method and device for synchronizing block chain state
JP6731201B2 (en) Time-based node selection method and apparatus
CN109165229B (en) Method, device, equipment and storage medium for checking local block synchronization
CN108924252B (en) Method, medium, and blockchain system for reducing storage load of nodes in blockchain system
US6167436A (en) Data acquisition system and storage medium for storing the data used in the same
CN107943718B (en) Method and device for cleaning cache file
CN106230997B (en) Resource scheduling method and device
CN112434039A (en) Data storage method, device, storage medium and electronic device
CN112615905B (en) Method, device and equipment for scheduling block chain fragments and storage medium
CN109379396B (en) Method, medium, device and block chain system for preventing hard branching phenomenon in block chain system
CN109241365B (en) Block chain system construction method, medium, computer equipment and block chain system
CN103701653B (en) The processing method of a kind of interface hot plug configuration data and network configuration server
CN116107828A (en) Main node selection method, distributed database and storage medium
CN111427931A (en) Distributed query engine and method for querying relational database by using same
CN105573851B (en) Flow cooperative processing method and system
CN114039891A (en) Sketch-based software-defined network large-flow end-to-end time delay and packet loss rate estimation method
CN106021026B (en) Backup method and device
CN116225834A (en) Alarm information sending method and device, storage medium and electronic device
CN106202293B (en) A kind of update method and device of emergency event corpus
JP6074828B2 (en) Method, base station, and network system for automatically deleting X2 configuration
CN113556573A (en) Method and system for selecting push flow link
CN105050128B (en) Utilize the node order automatic deduction method of the bridge health monitoring Sensor Network of signal strength
CN105824824B (en) Standby call ticket collection equipment and call ticket file collection method thereof
CN111383125B (en) Community dividing method, system, terminal equipment and storage medium
CN108255937A (en) Resource method for cleaning, device, storage medium and computer equipment based on SDN

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
CP03 Change of name, title or address
CP03 Change of name, title or address

Address after: 361000 B1F-065, Zone A, Huaxun Building, Software Park, Xiamen Torch Hi-tech Zone, Huli District, Xiamen City, Fujian Province

Patentee after: Ke'an (Xiamen) Technology Co.,Ltd.

Address before: B1f-065, zone a, Huaxun building, software park, torch hi tech Zone, Xiamen City, Fujian Province, 361000

Patentee before: TAILIAN (XIAMEN) TECHNOLOGY Co.,Ltd.