CN111475309A - Data processing method, device, block chain service system and storage medium - Google Patents

Data processing method, device, block chain service system and storage medium Download PDF

Info

Publication number
CN111475309A
CN111475309A CN201910067672.7A CN201910067672A CN111475309A CN 111475309 A CN111475309 A CN 111475309A CN 201910067672 A CN201910067672 A CN 201910067672A CN 111475309 A CN111475309 A CN 111475309A
Authority
CN
China
Prior art keywords
data
notification information
target data
synchronization node
application program
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.)
Pending
Application number
CN201910067672.7A
Other languages
Chinese (zh)
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 Jingdong Century Trading Co Ltd
Beijing Jingdong Shangke Information Technology Co Ltd
Original Assignee
Beijing Jingdong Century Trading Co Ltd
Beijing Jingdong Shangke 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 Jingdong Century Trading Co Ltd, Beijing Jingdong Shangke Information Technology Co Ltd filed Critical Beijing Jingdong Century Trading Co Ltd
Priority to CN201910067672.7A priority Critical patent/CN111475309A/en
Publication of CN111475309A publication Critical patent/CN111475309A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/546Message passing systems or structures, e.g. queues
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/52Program synchronisation; Mutual exclusion, e.g. by means of semaphores

Abstract

The invention discloses a data processing method, which is applied to a block chain network and comprises the following steps: receiving first notification information sent by a queue service program, wherein the first notification information carries subject messages subscribed by application programs corresponding to the queue service program; and when the data synchronization node in the block chain network completes data synchronization, the data synchronization node responds to the first notification information and pushes target data to the queue service program so as to realize that the target data is matched with the subject message carried by the first notification information. The invention also discloses a data processing device, a block chain service system and a storage medium.

Description

Data processing method, device, block chain service system and storage medium
Technical Field
The present invention relates to data processing technologies, and in particular, to a data processing method, an apparatus, a block chain service system, and a storage medium.
Background
In the prior art, when an application program wants to acquire data generated in the blockchain network, a JSON RPC interface provided by all nodes in the blockchain network can be adopted to realize user serialization reading of data stored in the blockchain; or reading binary data in a distributed database corresponding to the block chain network and then analyzing the binary data according to a protocol to form data of the block chain network to be acquired. However, in any processing method, the timeliness of the acquired blockchain network data is poor, and the use of the application program cannot be satisfied.
Disclosure of Invention
In view of this, embodiments of the present invention desirably provide a data processing method, an apparatus, a block chain service system, and a storage medium, which can push, by a data synchronization node of a block chain network, corresponding target data to an application program through a queue service program according to different topic messages (topic) of block chain network data subscribed by the application program, so as to enhance timeliness of the target data.
The technical scheme of the embodiment of the invention is realized as follows:
the invention provides a data processing method, which is applied to a block chain network and comprises the following steps:
receiving first notification information sent by a queue service program, wherein the first notification information carries subject messages subscribed by application programs corresponding to the queue service program;
and when the data synchronization node in the block chain network completes data synchronization, the data synchronization node responds to the first notification information and pushes target data to the queue service program so as to realize that the target data is matched with the subject message carried by the first notification information.
In the foregoing solution, the pushing, by the data synchronization node, target data to the queue service program in response to the first notification information includes:
the data synchronization node analyzes the theme message carried by the first notification information;
and according to the analyzed theme message, carrying out serialization processing on the data stored in the data synchronization node to form target data to be pushed.
In the foregoing solution, the serializing the data stored in the data synchronization node according to the parsed subject message to form target data to be pushed includes:
determining the priority of different theme messages in the first notification information according to the analyzed theme messages;
determining the processing sequence of different target data based on the determined priorities of different subject messages;
and sequentially carrying out serialization processing on the data stored by the data synchronization node based on the processing sequence of the different target data to form target data pushed to different subject messages of the queue service program.
In the foregoing solution, the serializing the data stored in the data synchronization node according to the parsed subject message to form target data to be pushed includes:
and rewriting the data stored by the data synchronization node according to the analyzed theme message to form target data matched with the application program.
In the above scheme, the method further comprises:
and the data synchronization node acquires the blocks generated by the adjacent nodes in the block chain network so as to update the block chain data stored by the data synchronization node.
In the above scheme, the method further comprises:
checking the blocks generated by the acquired adjacent nodes in the block chain network;
when the data passes the verification, storing the acquired data in the block in a distributed storage system corresponding to the data synchronization node;
and receiving a hash value sent by the distributed network, wherein the hash value is used for representing the storage position of the data to be stored in the distributed network.
The invention also provides a data processing method, which is applied to the queue service program and comprises the following steps:
receiving second notification information sent by an application program, wherein the second notification information carries a topic message subscribed by the program;
analyzing the second notification information to generate first notification information carrying a subject message;
sending the generated first notification information to a data synchronization node of the blockchain network;
receiving target data pushed by the data synchronization node;
pushing the received target data to the application to achieve matching of the target data with the application.
The invention also provides a data processing method, which is applied to the block chain service system and comprises the following steps:
the block chain network receives third notification information sent by an application program through a queue service program, wherein the third notification information carries subject information subscribed by the application program;
and when the data synchronization node in the block chain network completes data synchronization, the data synchronization node responds to the third notification information and pushes target data to the application program so as to realize that the target data is matched with the theme message carried by the third notification information.
The invention also provides a data processing device, which is applied to the block chain network, and the device comprises:
the system comprises a first data transmission module, a first data transmission module and a second data transmission module, wherein the first data transmission module is used for receiving first notification information sent by a queue service program, and the first notification information carries subject messages subscribed by application programs corresponding to the queue service program;
and the first data processing module is used for responding to the first notification information and pushing target data to the queue service program so as to realize that the target data is matched with the theme message carried by the first notification information.
In the above-mentioned scheme, the first step of the method,
the first data processing module is used for analyzing the theme message carried by the first notification information;
and the first data processing module is used for carrying out serialization processing on the data stored in the data synchronization node according to the analyzed theme message to form target data to be pushed.
In the above-mentioned scheme, the first step of the method,
the first data processing module is used for determining the priority of different theme messages in the first notification information according to the analyzed theme messages;
the first data processing module is used for determining the processing sequence of different target data based on the determined priorities of different subject messages;
and the first data processing module is used for sequentially carrying out serialization processing on the data stored by the data synchronization node based on the processing sequence of the different target data to form target data pushed to different subject messages of the queue service program.
In the above-mentioned scheme, the first step of the method,
and the first data processing module is used for rewriting the data stored by the data synchronization node according to the analyzed theme message so as to form target data matched with the application program.
In the above-mentioned scheme, the first step of the method,
the first data processing module is configured to acquire a block generated by an adjacent node in the blockchain network, so as to update blockchain data stored in the data synchronization node.
In the above scheme, the apparatus further comprises:
the checking module is used for checking the blocks generated by the adjacent nodes in the acquired block chain network;
the first data processing module is configured to, when the check is passed, store the data in the acquired block in a distributed storage system corresponding to the data synchronization node;
the first data transmission module is configured to receive a hash value sent by the distributed network, where the hash value is used to characterize a storage location of the data to be stored in the distributed network.
The invention also provides a data processing device, which is applied to the queue service program and comprises the following components:
the second data transmission module is used for receiving second notification information sent by an application program, wherein the second notification information carries a topic message subscribed by the program;
the second data processing module is used for analyzing the second notification information and generating first notification information carrying the theme message;
the second data processing module is used for sending the generated first notification information to a data synchronization node of the block chain network;
the second data transmission module is used for receiving the target data pushed by the data synchronization node;
and the second data transmission module is used for pushing the received target data to the application program so as to realize the matching of the target data and the application program.
The invention also provides a block chain service system, comprising:
the queue service program module is used for receiving third notification information sent by an application program, wherein the third notification information carries a theme message subscribed by the application program;
and the block chain network module is used for responding to the third notification information and pushing target data to the application program so as to realize that the target data is matched with the theme message carried by the third notification information.
The present invention also provides a data processing apparatus, comprising:
a memory for storing executable instructions;
and the processor is used for realizing the data processing method applied to the block chain network when the processor executes the executable instructions stored in the memory.
The invention also provides a storage medium, which is characterized in that executable instructions are stored, and the executable instructions are used for causing a processor to execute the data processing method applied to the block chain network.
The present invention also provides a data processing apparatus, characterized in that the apparatus comprises:
a processor and a memory for storing executable instructions capable of running on the processor,
wherein the processor is configured to execute the executable instructions to perform the following operations:
receiving second notification information sent by an application program, wherein the second notification information carries a topic message subscribed by the program;
analyzing the second notification information to generate first notification information carrying a subject message;
sending the generated first notification information to a data synchronization node of the blockchain network;
receiving target data pushed by the data synchronization node;
pushing the received target data to the application to achieve matching of the target data with the application.
The present invention also provides a computer-readable storage medium storing executable instructions that, when executed by a processor, perform operations comprising:
receiving second notification information sent by an application program, wherein the second notification information carries a topic message subscribed by the program;
analyzing the second notification information to generate first notification information carrying a subject message;
sending the generated first notification information to a data synchronization node of the blockchain network;
receiving target data pushed by the data synchronization node;
pushing the received target data to the application to achieve matching of the target data with the application.
The present invention also provides a block chain service system, which is characterized in that the block chain service system comprises:
a processor and a memory for storing executable instructions capable of running on the processor,
wherein the processor is configured to execute the executable instructions to perform the following operations:
the block chain network receives third notification information sent by an application program through a queue service program, wherein the third notification information carries subject information subscribed by the application program;
and when the data synchronization node in the block chain network completes data synchronization, the data synchronization node responds to the third notification information and pushes target data to the application program so as to realize that the target data is matched with the theme message carried by the third notification information.
The present invention also provides a computer-readable storage medium storing executable instructions that, when executed by a processor, perform operations comprising:
the block chain network receives third notification information sent by an application program through a queue service program, wherein the third notification information carries subject information subscribed by the application program;
and when the data synchronization node in the block chain network completes data synchronization, the data synchronization node responds to the third notification information and pushes target data to the application program so as to realize that the target data is matched with the theme message carried by the third notification information.
In the embodiment of the invention, first notification information sent by a queue service program is received, wherein the first notification information carries subject messages subscribed by application programs corresponding to the queue service program; and when the data synchronization node in the block chain network completes data synchronization, the data synchronization node responds to the first notification information and pushes target data to the queue service program so as to realize that the target data is matched with the subject message carried by the first notification information. Therefore, the data synchronization node of the block chain network pushes the corresponding target data to the application program through the queue service program, the pushed target data is high in timeliness, and meanwhile, the pushed target data can be matched with the theme message, so that secondary processing of the application program on the acquired block chain network data is saved.
Drawings
Fig. 1 is a schematic functional architecture diagram of a block chain network according to an embodiment of the present invention;
fig. 2 is a schematic diagram of an organization architecture of a block chain network according to an embodiment of the present invention;
fig. 3 is an alternative structural schematic diagram of a consensus node according to an embodiment of the present invention;
FIG. 4 is a schematic flow chart of an alternative data processing method according to an embodiment of the present invention;
FIG. 5 is a schematic diagram of an alternative embodiment of a data processing apparatus 500;
FIG. 6 is a schematic flow chart of an alternative data processing method according to an embodiment of the present invention;
FIG. 7 is a schematic diagram of an alternative embodiment of a data processing apparatus 700;
FIG. 8 is a schematic flow chart diagram illustrating an alternative data processing method according to an embodiment of the present invention;
fig. 9 is an alternative block chain service system 900 according to an embodiment of the present invention;
FIG. 10 is a schematic flow chart diagram illustrating an alternative data processing method according to an embodiment of the present invention;
FIG. 11 is a schematic diagram of an alternative usage scenario of the data processing method according to the embodiment of the present invention;
FIG. 12 is a schematic diagram of an alternative usage scenario of the data processing method according to the embodiment of the present invention;
FIG. 13 is a schematic diagram of an alternative embodiment of a data processing apparatus;
FIG. 14 is a schematic diagram of an alternative embodiment of a data processing apparatus;
fig. 15 is an alternative block chain service system according to an embodiment of the invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention clearer, the present invention will be further described in detail with reference to the accompanying drawings, the described embodiments should not be construed as limiting the present invention, and all other embodiments obtained by a person of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.
Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs. The terminology used herein is for the purpose of describing embodiments of the invention only and is not intended to be limiting of the invention.
Before further detailed description of the embodiments of the present invention, terms and expressions mentioned in the embodiments of the present invention are explained, and the terms and expressions mentioned in the embodiments of the present invention are applied to the following explanations.
1) The system comprises a full node and a node with a complete block chain account book, wherein the full node needs to occupy a memory to synchronize all block chain data, can independently check all transactions on the block chain and update the data in real time, is mainly responsible for broadcasting and verifying the transactions of the block chain, and can be served by the full node in the personal application.
2) The Block (Block) records a data structure of the account book data updated in the transaction within a period of time, is marked with a timestamp and a unique mark (such as a digital fingerprint) of a previous Block, and is added to the end of a Block chain to become a new Block after the Block is subjected to consensus verification of nodes in the Block chain network, wherein the data generated by the Block chain is stored in the Block.
3) A chain of blocks (Blockchain), a chain of data structures in which blocks are assembled in a sequentially contiguous manner, each block having a hash value of a previous block or a subset thereof referenced therein, to cryptographically secure the recorded transaction against tampering and forgery.
4) A blockchain network incorporates new blocks into a set of centerless nodes of the blockchain in a consensus manner.
5) The ledger data, the actual block data storage, i.e. the record of a series of ordered and non-falsifiable transactions recorded in the block chain, may be expressed in the form of a file system, and the update of the data in the account/account is realized when an intelligent contract called in the transaction is executed.
6) Distributed File System (Distributed File System) means that the physical storage resources managed by the File System are not necessarily directly connected to the local nodes, but are connected to the nodes through a computer network. The design of the distributed file system is based on a client/server model. A typical network may include multiple servers for access by multiple users.
7) Asymmetric encryption algorithm: two keys are required, a public key (public key) and a private key (private key). The public key and the private key are a pair, and if the public key is used for encrypting data, only the corresponding private key can be used for decrypting the data; if the data is encrypted with a private key, it can only be decrypted with the corresponding public key. Because two different keys are used for encryption and decryption
8) Consensus (Consensus), a process in a blockchain network, is used to agree on the transaction results among the nodes involved, and the mechanisms for achieving Consensus include Proof of workload (PoW), Proof of rights and interests (PoS, Proof of approval of stamp), Proof of share authorization (DPoS), Proof of Elapsed Time (PoET, Proof of Elapsed Time), and so on.
9) Intelligent Contracts (Smart Contracts), also called chain codes (chaincodes), are deployed in the blockchain network, and trigger the execution of programs according to conditions, and are used for operating the ledger through query, addition and modification so as to realize query or update of the ledger.
10) In response to the condition or state on which the performed operation depends, one or more of the performed operations may be in real-time or may have a set delay when the dependent condition or state is satisfied; there is no restriction on the order of execution of the operations performed unless otherwise specified.
An exemplary functional architecture of a block chain network for implementing the embodiment of the present invention is described below, and referring to fig. 1, fig. 1 is a schematic functional architecture diagram of a block chain network provided in the embodiment of the present invention, which includes an application layer 101, a consensus layer 102, a network layer 103, a data layer 104, and a resource layer 105, which are described below respectively.
The resource layer 105 encapsulates various available computing and storage resources, such as those in computers, servers/clusters, and clouds, abstracts and provides a uniform interface to the data layer 104 to mask the variability of the underlying hardware implementing the resource layer 105.
The computing resources include various forms of processors such as a Central Processing Unit (CPU), an Application Specific Integrated Circuit (ASIC), and a Field-Programmable Gate Array (FPGA).
The storage resources include various types of storage media such as various volatile memories and nonvolatile memories. The nonvolatile Memory may be a Read Only Memory (ROM) or a Programmable Read-Only Memory (PROM). Volatile Memory can be Random Access Memory (RAM), which acts as external cache Memory.
The computing resources and storage resources of the resource layer 105 may be mapped to various types of nodes in a blockchain network, and the storage medium implementing an embodiment of the present invention stores executable instructions for implementing the blockchain network deployment method of an embodiment of the present invention, and once the executable instructions deployed to the nodes are executed, the underlying resources (e.g., various types of processors) implementing the nodes will implement the deployment of various types of nodes in the blockchain network and perform the functions of the various types of nodes, thereby implementing ledgers for transactions in business processes and various applications based on the ledgers.
By way of example, executable instructions may be written in any form of programming language, including compiled or interpreted languages, or declarative or procedural languages, in the form of software (including system programs and applications), software modules, scripts, plug-ins, and the like, and may be deployed in any form, including as a stand-alone program or as a module, component, or other unit suitable for use in a computing environment.
Data layer 104 encapsulates various data structures that implement the ledger, including ledger data implemented in a file system, ledger state and presence proofs implemented in a database form.
Network layer 103 encapsulates point-to-point (P2P) network protocols, data propagation and verification mechanisms, access and authentication mechanisms, and service agent identities. The P2P network protocol realizes communication among nodes in the blockchain network, a data propagation mechanism ensures the propagation of transaction/transaction results in the blockchain network, and a data verification mechanism is used for realizing the reliability of data transmission among the nodes based on an encryption method (such as a digital certificate, a digital signature and a public/private key pair); the access and authentication mechanism is used for managing the access and authentication of the terminal based on the identity of the service subject.
The consensus layer 102 encapsulates mechanisms for achieving consistency of transaction results propagated in the block chain, including POS, POW, DPOS, etc., and supports pluggable consensus mechanisms.
The application layer 101 encapsulates various services that the blockchain network can implement, including transaction settlement, tracing, and evidence storage.
An exemplary organization architecture of a blockchain network implementing an embodiment of the present invention is described below, referring to fig. 2, fig. 2 is a schematic organization architecture diagram of a blockchain network provided by an embodiment of the present invention, and includes at least two consensus nodes 110, and fig. 2 only shows a consensus node 110-1 and a consensus node 110-2 as an example; the consensus node 110-1 and the consensus node 110-2 are correspondingly deployed for the roles implemented in the service by two different service entities participating in the service. The blockchain network 100 responds to transactions submitted by the terminal 300 from the business entity to update the ledger or to query the ledger and displays various intermediate or final results in the user interface 310 of the terminal 300.
An exemplary structure of a node in the blockchain network implementing the embodiment of the present invention is described below by taking the common node as an example, and it is understood that the hardware structure of other nodes in the blockchain network 100 may be implemented according to the hardware structure of the common node.
Referring to fig. 3, fig. 3 is an optional structural schematic diagram of the consensus node 110 according to an embodiment of the present invention, where the consensus node 110 may be one or more servers, and according to the structure of the consensus node 110, other exemplary structures of the consensus node 110 may be foreseen, and therefore, the structure described herein should not be considered as a limitation, for example, some components described below may be omitted, or components not described below may be added to adapt to special requirements of some application scenarios.
Fig. 4 is an optional flowchart of a data processing method according to an embodiment of the present invention, where the method shown in fig. 4 is applied to a blockchain network, and the optional flowchart of the data processing method includes the following steps:
step 401: receiving first notification information sent by a queue service program;
step 402: the data synchronization node in the block chain network judges whether the data synchronization is finished, if so, step 403 is executed, otherwise, step 404 is executed;
step 403: the data synchronization node analyzes the theme message carried by the first notification information;
step 404: the data synchronization process in the blockchain network continues to be monitored.
Step 405: and according to the analyzed theme message, carrying out serialization processing on the data stored in the data synchronization node to form target data to be pushed.
Step 406: and the data synchronization node responds to the first notification information and pushes target data to the queue service program.
Therefore, the target data can be matched with the theme message carried by the first notification information.
In an embodiment of the present invention, the serializing the data stored in the data synchronization node according to the parsed subject message to form target data to be pushed includes:
determining the priority of different theme messages in the first notification information according to the analyzed theme messages; determining the processing sequence of different target data based on the determined priorities of different subject messages; and sequentially carrying out serialization processing on the data stored by the data synchronization node based on the processing sequence of the different target data to form target data pushed to different subject messages of the queue service program. Since the number of the application programs subscribing the topic message to the queue service program may be large, according to the technical scheme shown in this embodiment, the processing order of different target data is determined by determining the priorities of different topic messages, and the target data required by the topic message with higher priority can be preferentially processed, so as to reduce the waiting time for the application program corresponding to the topic message with higher priority to acquire the target data. Specifically, the priorities of different topic messages in the first notification information may be characterized by the priority identifiers of the topic messages, and optionally, the topic message subscribed by the application program, where the application program pays a fee to the blockchain network and/or the queue service program operator, has a higher priority than the topic message subscribed by the application program that obtains the target data for free.
In an embodiment of the present invention, the serializing the data stored in the data synchronization node according to the parsed subject message to form target data to be pushed includes:
and rewriting the data stored by the data synchronization node according to the analyzed theme message to form target data matched with the application program. In the existing technical solution, because the data acquired by the application from all nodes of the blockchain network is in a fixed format, the application often needs to request target data from all nodes of the blockchain network many times in order to complete the application, which easily causes data redundancy, and wastes the data processing capability of all nodes of the blockchain network, according to the analyzed topic message, the data stored in the data synchronization node is rewritten, and the application acquires the target data corresponding to the subscribed topic message, which avoids the secondary processing of the application on the acquired data, saves the processing event of the application on the data, improves the data processing efficiency, and meanwhile, the pushed target data has stronger adaptability. Specifically, when the application program has a function of processing ticket service data, the topic message subscribed by the application program is a ticket; the data synchronization node carries out serialization processing and rewriting on the updated data according to the theme message to form bill data to be pushed, so that the defect that the application program can only form usable bill data through secondary processing on the acquired data is overcome; furthermore, the data synchronization node can also perform iterative processing on the stored data according to the analyzed first notification message, and periodically send the data to the service queue program, so that the defect that the application program frequently requests the data synchronization node for the data is avoided.
In one embodiment of the invention, the method further comprises:
and the data synchronization node acquires the blocks generated by the adjacent nodes in the block chain network so as to update the block chain data stored by the data synchronization node. In the process of pushing the target data, the data synchronization node pushes the target data with the highest real-time property matched with the subject message, so that the application program can receive the pushing immediately after the data synchronization node in the blockchain network updates the data.
In one embodiment of the invention, the method further comprises:
checking the blocks generated by the acquired adjacent nodes in the block chain network; when the data passes the verification, storing the acquired data in the block in a distributed storage system corresponding to the data synchronization node; and receiving a hash value sent by the distributed network, wherein the hash value is used for characterizing the storage position of the data in the block in the distributed network. According to the technical scheme shown in the embodiment, when the used distributed network is an InterPlanetary File storage System (InterPlanetary File System), if the data to be stored exceeds a specification threshold value of 256K, the data to be stored is divided to form a plurality of data blocks; storing the plurality of data blocks in a plurality of nodes of the distributed network; the number of the nodes is equal to the number of the data blocks, and due to the uniqueness of the hash value, when the data to be stored in any one node changes, the corresponding hash value also changes, so that the data to be stored is prevented from being maliciously modified.
In one embodiment of the invention, the method further comprises:
encrypting the data in the block according to the type of the data in the block;
decrypting the received data corresponding to the hash value to form plaintext data usable by the blockchain network and/or the respective application. In an embodiment of the present invention, the acquired data to be stored may be ciphertext data subjected to asymmetric encryption processing, or plaintext data subjected to encryption processing, where whether the data to be stored is encrypted or not needs to be processed according to an instruction of a data attribution user.
In an embodiment of the present invention, when an application in a blockchain network corresponding to the distributed network needs to encrypt corresponding data to be stored, the distributed network may encrypt the data to be stored according to an encryption identifier of the data to be stored. By the technical scheme shown in the embodiment, the data to be stored can be automatically encrypted according to the encryption identifier.
Fig. 5 is an optional component schematic diagram of a data processing apparatus 500 according to an embodiment of the present invention, and as shown in fig. 5, the data processing apparatus is applied in a blockchain network, and an optional component structure of the data processing apparatus 500 includes:
a first data transmission module 501, configured to receive first notification information sent by a queue service program, where the first notification information carries a topic message subscribed by an application program corresponding to the queue service program;
a first data processing module 502, configured to respond to the first notification information, and push target data to the queue service program. Therefore, the target data can be matched with the theme message carried by the first notification information.
In an embodiment of the present invention, the first data processing module 502 is configured to parse a theme message carried by the first notification information; the first data processing module 502 is configured to perform serialization processing on the data stored in the data synchronization node according to the parsed subject message, so as to form target data to be pushed. Since the number of the application programs subscribing the topic message to the queue service program may be large, according to the technical scheme shown in this embodiment, the processing order of different target data is determined by determining the priorities of different topic messages, and the target data required by the topic message with higher priority can be preferentially processed, so as to reduce the waiting time for the application program corresponding to the topic message with higher priority to acquire the target data. Specifically, the priorities of different topic messages in the first notification information may be characterized by the priority identifiers of the topic messages, and optionally, the topic message subscribed by the application program, where the application program pays a fee to the blockchain network and/or the queue service program operator, has a higher priority than the topic message subscribed by the application program that obtains the target data for free.
In an embodiment of the present invention, the first data processing module 502 is configured to determine priorities of different topic messages in the first notification information according to the parsed topic message; the first data processing module 502 is configured to determine a processing order of different target data based on the determined priorities of different subject messages; the first data processing module 502 is configured to sequentially perform serialization processing on the data stored in the data synchronization node based on the processing sequence of the different target data, so as to form target data pushed to different subject messages of the queue service program. Since the number of the application programs subscribing the topic message to the queue service program may be large, according to the technical scheme shown in this embodiment, the processing order of different target data is determined by determining the priorities of different topic messages, and the target data required by the topic message with higher priority can be preferentially processed, so as to reduce the waiting time for the application program corresponding to the topic message with higher priority to acquire the target data. Specifically, the priorities of different topic messages in the first notification information may be characterized by the priority identifiers of the topic messages, and optionally, the topic message subscribed by the application program, where the application program pays a fee to the blockchain network and/or the queue service program operator, has a higher priority than the topic message subscribed by the application program that obtains the target data for free.
In an embodiment of the present invention, the first data processing module 502 is configured to rewrite data stored in the data synchronization node according to the parsed subject message, so as to form target data matched with the application program. In the existing technical solution, because the data acquired by the application from all nodes of the blockchain network is in a fixed format, the application often needs to request target data from all nodes of the blockchain network many times in order to complete the application, which easily causes data redundancy, and wastes the data processing capability of all nodes of the blockchain network, according to the analyzed topic message, the data stored in the data synchronization node is rewritten, and the application acquires the target data corresponding to the subscribed topic message, which avoids the secondary processing of the application on the acquired data, saves the processing event of the application on the data, improves the data processing efficiency, and meanwhile, the pushed target data has stronger adaptability. Specifically, when the application program has a function of processing ticket service data, the topic message subscribed by the application program is a ticket; the data synchronization node carries out serialization processing and rewriting on the updated data according to the theme message to form bill data to be pushed, so that the defect that the application program can only form usable bill data through secondary processing on the acquired data is overcome; furthermore, the data synchronization node can also perform iterative processing on the stored data according to the analyzed first notification message, and periodically send the data to the service queue program, so that the defect that the application program frequently requests the data synchronization node for the data is avoided.
In an embodiment of the present invention, the first data processing module 502 is configured to obtain a block generated by a neighboring node in the blockchain network, so as to update blockchain data stored in the data synchronization node. In the process of pushing the target data, the data synchronization node pushes the target data with the highest real-time property matched with the subject message, so that the application program can receive the pushing immediately after the data synchronization node in the blockchain network updates the data.
In one embodiment of the invention, the apparatus further comprises:
a checking module (not shown in the figure) for checking the blocks generated by the adjacent nodes in the acquired block chain network; the first data processing module 502 is configured to, when the check is passed, store the acquired data in the block in the distributed storage system corresponding to the data synchronization node; the first data transmission module 501 is configured to receive a hash value sent by the distributed network, where the hash value is used to characterize a storage location of the data to be stored in the distributed network. According to the technical scheme shown in the embodiment, when the used distributed network is an InterPlanetary File storage System (InterPlanetary File System), if the data to be stored exceeds a specification threshold value of 256K, the data to be stored is divided to form a plurality of data blocks; storing the plurality of data blocks in a plurality of nodes of the distributed network; the number of the nodes is equal to the number of the data blocks, and due to the uniqueness of the hash value, when the data to be stored in any one node changes, the corresponding hash value also changes, so that the data to be stored is prevented from being maliciously modified.
In an embodiment of the present invention, the first data processing module 502 is configured to encrypt the data in the block according to a type of the data in the block;
decrypting the received data corresponding to the hash value to form plaintext data usable by the blockchain network and/or the respective application. In an embodiment of the present invention, the acquired data to be stored may be ciphertext data subjected to asymmetric encryption processing, or plaintext data subjected to encryption processing, where whether the data to be stored is encrypted or not needs to be processed according to an instruction of a data attribution user.
In an embodiment of the present invention, when an application in a blockchain network corresponding to the distributed network needs to encrypt corresponding data to be stored, the distributed network may encrypt the data to be stored according to an encryption identifier of the data to be stored. By the technical scheme shown in the embodiment, the data to be stored can be automatically encrypted according to the encryption identifier.
Fig. 6 is an optional flowchart of a data processing method according to an embodiment of the present invention, where the method shown in fig. 6 is applied to a queue service program, and an optional flowchart of the data processing method includes the following steps:
step 601: and receiving second notification information sent by the application program.
Wherein the second notification information carries a topic message subscribed by the program;
step 602: analyzing the second notification information to generate first notification information carrying a subject message;
step 603: sending the generated first notification information to a data synchronization node of the blockchain network;
step 604: receiving target data pushed by the data synchronization node;
step 605: pushing the received target data to the application.
Thereby, matching of the target data with the application program can be achieved. In the existing technical solution, because the data acquired by the application from all nodes of the blockchain network is in a fixed format, the application often needs to request target data from all nodes of the blockchain network many times in order to complete the application, which easily causes data redundancy, and wastes the data processing capability of all nodes of the blockchain network, according to the analyzed topic message, the data stored in the data synchronization node is rewritten, and the application acquires the target data corresponding to the subscribed topic message, which avoids the secondary processing of the application on the acquired data, saves the processing event of the application on the data, improves the data processing efficiency, and meanwhile, the pushed target data has stronger adaptability. Specifically, when the application program has a function of processing ticket service data, the topic message subscribed by the application program is a ticket; the data synchronization node carries out serialization processing and rewriting on the updated data according to the theme message to form bill data to be pushed, so that the defect that the application program can only form usable bill data through secondary processing on the acquired data is overcome; furthermore, the data synchronization node can also perform iterative processing on the stored data according to the analyzed first notification message, and periodically send the data to the service queue program, so that the defect that the application program frequently requests the data synchronization node for the data is avoided.
Fig. 7 is an optional component schematic diagram of a data processing apparatus 700 according to an embodiment of the present invention, and as shown in fig. 7, the data processing apparatus is applied to a queue service program, and an optional component structure of the data processing apparatus 700 includes:
a second data transmission module 701, configured to receive second notification information sent by an application program, where the second notification information carries a topic message subscribed by the application program;
a second data processing module 702, configured to analyze the second notification information and generate first notification information carrying a theme message;
the second data processing module 702 is configured to send the generated first notification information to a data synchronization node of a blockchain network;
the second data transmission module 701 is configured to receive target data pushed by the data synchronization node;
the second data transmission module 701 is configured to push the received target data to the application program, so as to implement matching between the target data and the application program.
Thereby, matching of the target data with the application program can be achieved. In the existing technical solution, because the data acquired by the application from all nodes of the blockchain network is in a fixed format, the application often needs to request target data from all nodes of the blockchain network many times in order to complete the application, which easily causes data redundancy, and wastes the data processing capability of all nodes of the blockchain network, according to the analyzed topic message, the data stored in the data synchronization node is rewritten, and the application acquires the target data corresponding to the subscribed topic message, which avoids the secondary processing of the application on the acquired data, saves the processing event of the application on the data, improves the data processing efficiency, and meanwhile, the pushed target data has stronger adaptability. Specifically, when the application program has a function of processing ticket service data, the topic message subscribed by the application program is a ticket; the data synchronization node carries out serialization processing and rewriting on the updated data according to the theme message to form bill data to be pushed, so that the defect that the application program can only form usable bill data through secondary processing on the acquired data is overcome; furthermore, the data synchronization node can also perform iterative processing on the stored data according to the analyzed first notification message, and periodically send the data to the service queue program, so that the defect that the application program frequently requests the data synchronization node for the data is avoided.
Fig. 8 is an optional flowchart of a data processing method according to an embodiment of the present invention, where the method shown in fig. 8 is applied to a blockchain service system, and the optional flowchart of the data processing method includes the following steps:
step 801: and the blockchain network receives third notification information sent by the application program through the queue service program.
Wherein the third notification information carries a topic message subscribed by the application program;
step 802: and when the data synchronization node in the block chain network completes data synchronization, the data synchronization node responds to the third notification information and pushes target data to the application program.
Therefore, the target data can be matched with the theme message carried by the third notification information.
In an embodiment of the present invention, the serializing the data stored in the data synchronization node according to the parsed subject message to form target data to be pushed includes:
the data synchronization node determines the priority of different theme messages in the third notification information according to the analyzed theme messages; the data synchronization node determines the processing sequence of different target data based on the determined priorities of different subject messages; and the data synchronization node sequentially carries out serialization processing on the data stored by the data synchronization node based on the processing sequence of the different target data to form target data pushed to different subject messages of the queue service program. Since the number of the application programs subscribing the topic message to the queue service program may be large, according to the technical scheme shown in this embodiment, the processing order of different target data is determined by determining the priorities of different topic messages, and the target data required by the topic message with higher priority can be preferentially processed, so as to reduce the waiting time for the application program corresponding to the topic message with higher priority to acquire the target data. Specifically, the priorities of different topic messages in the third notification information may be characterized by the priority identifiers of the topic messages, and optionally, the topic message subscribed by the application program, where the application program pays a fee to the blockchain network and/or the queue service program operator, has a higher priority than the topic message subscribed by the application program that obtains the target data for free.
In an embodiment of the present invention, the serializing the data stored in the data synchronization node according to the parsed subject message to form target data to be pushed includes:
and the data synchronization node rewrites the data stored by the data synchronization node according to the analyzed theme message to form target data matched with the application program. In the existing technical solution, because the data acquired by the application from all nodes of the blockchain network is in a fixed format, the application often needs to request target data from all nodes of the blockchain network many times in order to complete the application, which easily causes data redundancy, and wastes the data processing capability of all nodes of the blockchain network, according to the analyzed topic message, the data stored in the data synchronization node is rewritten, and the application acquires the target data corresponding to the subscribed topic message, which avoids the secondary processing of the application on the acquired data, saves the processing event of the application on the data, improves the data processing efficiency, and meanwhile, the pushed target data has stronger adaptability. Specifically, when the application program has a function of processing ticket service data, the topic message subscribed by the application program is a ticket; the data synchronization node carries out serialization processing and rewriting on the updated data according to the theme message to form bill data to be pushed, so that the defect that the application program can only form usable bill data through secondary processing on the acquired data is overcome; furthermore, the data synchronization node can also perform iterative processing on the stored data according to the analyzed first notification message, and periodically send the data to the service queue program, so that the defect that the application program frequently requests the data synchronization node for the data is avoided.
In one embodiment of the present invention, the data synchronization node is capable of checking the acquired blocks generated by the neighboring nodes in the blockchain network; when the data passes the verification, storing the acquired data in the block in a distributed storage system corresponding to the data synchronization node; and receiving a hash value sent by the distributed network, wherein the hash value is used for representing the storage position of the data to be stored in the distributed network. Optionally, the data synchronization node is a full node in a corresponding block chain network. According to the technical scheme shown in the embodiment, when the used distributed network is an InterPlanetary File storage System (InterPlanetary File System), if the data to be stored exceeds a specification threshold value of 256K, the data to be stored is divided to form a plurality of data blocks; storing the plurality of data blocks in a plurality of nodes of the distributed network; the number of the nodes is equal to the number of the data blocks, and due to the uniqueness of the hash value, when the data to be stored in any one node changes, the corresponding hash value also changes, so that the data to be stored is prevented from being maliciously modified.
Fig. 9 is an alternative composition schematic diagram of a blockchain service system 900 according to an embodiment of the present invention, and as shown in fig. 9, an alternative composition structure of the blockchain service system 900 includes:
a queue service program module 901, configured to receive third notification information sent by an application program, where the third notification information carries a topic message subscribed by the application program;
and a blockchain network module 902, configured to, in response to the third notification information, push target data to the application program, so as to implement matching between the target data and a theme message carried by the third notification information. Therefore, the target data can be matched with the theme message carried by the third notification information. Wherein the queue service program module 901 is assumed by the corresponding interface of the blockchain network module 902.
Fig. 10 is an optional flowchart of a data processing method according to an embodiment of the present invention, where the method shown in fig. 10 is applied to a blockchain service system formed by a blockchain network and a queue service program, the blockchain service system may perform data interaction with different application programs, the application programs may implement completing transactions by activating corresponding intelligent contracts, recording ledger data, and implementing consensus, where the type and the number of the blockchain network are not limited, and an optional flowchart of the data processing method includes the following steps:
step 1001: the fourth notification information is sent to the queue service program by the application program;
therefore, the application program can subscribe the corresponding topic message to the queue service program.
Step 1002: the queue service program analyzes the fourth notification information and generates fifth notification information carrying subject information;
step 1003: the queue service program sends the fifth notification message to a data synchronization node of the blockchain network;
step 1004: and the data synchronization node receives fifth notification information sent by the queue service program.
Step 1005: and the data synchronization node responds to the fifth notification message and pushes target data to the queue service program.
Step 1006: and the queue service program receives the target data pushed by the data synchronization node.
Step 1007: the queue service program pushes the received target data to the application program.
Step 1008: and after receiving the target data pushed by the queue service program, the application program updates and analyzes the data in real time according to the self requirement.
In the existing technical solution, because the data acquired by the application from all nodes of the blockchain network is in a fixed format, the application often needs to request target data from all nodes of the blockchain network many times in order to complete the application, which easily causes data redundancy, and wastes the data processing capability of all nodes of the blockchain network, according to the analyzed topic message, the data stored in the data synchronization node is rewritten, and the application acquires the target data corresponding to the subscribed topic message, which avoids the secondary processing of the application on the acquired data, saves the processing event of the application on the data, improves the data processing efficiency, and meanwhile, the pushed target data has stronger adaptability.
Fig. 11 is a schematic diagram of an optional usage scenario of the data processing method according to an embodiment of the present invention, in the usage scenario shown in fig. 11, the application program is capable of implementing transaction completion and ledger data recording and implementing consensus by activating a corresponding smart contract, and the blockchain service system includes:
blockchain network group 1110 includes full nodes 1111, 1112, 1113, 1114, 1115 of different blockchain networks and application group 1120, including application group nodes 1121, 1122, 1123, 1124, and 1125. Furthermore, as shown in fig. 11, each of the full node 1111-1115 and the application group node 1120-1125 of the block-chain network may be an electronic device with computing and caching functions, and the electronic device may be a server or a user device (e.g., a mobile device such as a smart phone, a tablet computer, a portable computer, etc., or a fixed device such as a desktop computer). Those skilled in the art will appreciate that fig. 11 shows only a portion of the nodes of the blockchain network group and application group, which may also include more nodes.
In an embodiment of the present invention, the data blocks are synchronized among the block chain nodes 1111 and 1115 in the block chain network 1110 through a network, the nodes 1121 and 1125 in the application group 1120 realize data interaction through the network, and the block chain network 1110 and the application group 1120 are connected through a queue service group. The queue service group can be any wired and/or wireless network. The network may include, but is not limited to, the internet, a wide area network, a metropolitan area network, a week area network, a Virtual Private Network (VPN) network, a wireless communication network, etc., and the queue service group includes different subject messages, while the number of applications included is not limited.
In an embodiment of the present invention, the data synchronization node is configured to analyze a subject message carried by the first notification information, and the data synchronization node is configured to perform serialization processing on data stored in the data synchronization node according to the analyzed subject message, so as to form target data to be pushed. Since the number of the application programs subscribing the topic message to the queue service program may be large, according to the technical scheme shown in this embodiment, the processing order of different target data is determined by determining the priorities of different topic messages, and the target data required by the topic message with higher priority can be preferentially processed, so as to reduce the waiting time for the application program corresponding to the topic message with higher priority to acquire the target data. Specifically, the priorities of different topic messages in the first notification information may be characterized by the priority identifiers of the topic messages, and optionally, the topic message subscribed by the application program, where the application program pays a fee to the blockchain network and/or the queue service program operator, has a higher priority than the topic message subscribed by the application program that obtains the target data for free. And the target data is the occupation data and/or the corresponding transaction data. The data synchronization node can perform iterative processing on the stored block chain network data according to the first notification message, so as to automatically send target data matched with the subject message carried by the first notification message to the service queue program.
Fig. 12 is a schematic diagram of an optional usage scenario of the data processing method according to an embodiment of the present invention, in the usage scenario shown in fig. 12, the application program is capable of implementing transaction completion and ledger data recording and implementing consensus by activating a corresponding smart contract, and the blockchain service system includes:
blockchain network group 1110 includes full nodes 1111, 1112, 1113, 1114, 1115 of different blockchain networks and application group 1120, including application group nodes 1121, 1122, 1123, 1124, and 1125. Furthermore, as shown in fig. 12, each of the full node 1111-1115 and the application group node 1120-1125 of the block-chain network may be an electronic device with computing and caching functions, and the electronic device may be a server or a user device (e.g., a mobile device such as a smart phone, a tablet computer, a portable computer, etc., or a fixed device such as a desktop computer). Those skilled in the art will appreciate that fig. 12 shows only a portion of the nodes of the blockchain network group and application group, which may also include more nodes.
In an embodiment of the present invention, the data blocks are synchronized among the block chain nodes 1111 and 1115 in the block chain network 1110 through a network, the nodes 1121 and 1125 in the application group 1120 realize data interaction through the network, and the block chain network 1110 and the application group 1120 are connected through a queue service group. The queue service group can be any wired and/or wireless network. The network may include, but is not limited to, the internet, a wide area network, a metropolitan area network, a week area network, a Virtual Private Network (VPN) network, a wireless communication network, etc., and the queue service group includes different subject messages, while the number of applications included is not limited. Unlike the usage scenario diagram shown in fig. 11, a queue service group is assumed by a part of interfaces in the blockchain network group 1110 to implement data interaction with the application group.
Fig. 13 is a schematic diagram of an alternative configuration of a data processing apparatus according to an embodiment of the present invention, and as shown in fig. 13, the data processing apparatus 1300 may be a device including a data processing function and applied in a blockchain network. The data processing apparatus 1300 shown in fig. 13 includes: at least one processor 1301, memory 1302, at least one network interface 1304, and a user interface 1303. The various components in the data processing device 1300 are coupled together by a bus system 1305. It is understood that the bus system 1305 is used to implement connective communication between these components. The bus system 1305 includes a power bus, a control bus, and a status signal bus in addition to a data bus. For clarity of illustration, however, the various buses are labeled in FIG. 13 as the bus system 1305.
The user interface 1303 may include a display, a keyboard, a mouse, a trackball, a click wheel, a key, a button, a touch pad, a touch screen, or the like, among others.
It will be appreciated that the memory 1302 can be either volatile memory or nonvolatile memory, and can include both volatile and nonvolatile memory. The memory 1302 described in connection with the embodiments of the invention is intended to comprise these and any other suitable types of memory.
The memory 1302 in the embodiment of the present invention is used to store various types of data including the storage information to support the operation of the data processing apparatus 1300. Examples of such data include: any computer programs for operating on the data processing apparatus 1300, such as an operating system 13021 and application programs 13022; transaction data, user information, intelligent contracts, etc. The operating system 13021 includes various system programs, such as a framework layer, a core library layer, a driver layer, and the like, for implementing various basic services and processing hardware-based tasks. The application 13022 may contain various applications such as a client with a data processing function, a Media Player (Media Player), a Browser (Browser), etc. for implementing various application services including through the data processing program. A program for implementing the data processing method according to the embodiment of the present invention can be included in the application 13022.
The method disclosed by the above embodiment of the present invention may be applied to the processor 1301, or implemented by the processor 1301. Processor 1301 may be an integrated circuit chip having signal processing capabilities. In implementation, the steps of the method may be implemented by operations in the form of hardware, integrated logic circuits or software in the processor 1301. The Processor 1301 described above may be a general purpose Processor, a Digital Signal Processor (DSP), or other programmable logic device, discrete gate or transistor logic device, discrete hardware components, or the like. Processor 1301 may implement or perform the methods, steps, and logic blocks disclosed in the embodiments of the present invention. A general purpose processor may be a microprocessor or any conventional processor or the like. The steps of the method disclosed by the embodiment of the invention can be directly implemented by a hardware decoding processor, or can be implemented by combining hardware and software modules in the decoding processor. The software modules may be located in a storage medium that is located in the memory 1302, and the processor 1301 reads the information in the memory 1302 to perform the steps of the aforementioned methods in conjunction with its hardware.
In an exemplary embodiment, the data processing apparatus 1300 may be implemented by one or more Application Specific Integrated Circuits (ASICs), DSPs, Programmable logic devices (P L D, Programmable L) Complex Programmable logic devices (CP L D, Complex Programmable L) analog devices, Field Programmable Gate Arrays (FPGAs), general purpose processors, controllers, Micro Controllers (MCUs), microprocessors (microprocessors), or other electronic components for performing the object data processing method.
In an exemplary embodiment, the present invention further provides a computer readable storage medium, such as the memory 1302 including a computer program, which is executable by the processor 1301 of the data processing apparatus 1300 to perform the steps of the aforementioned method. The computer readable storage medium may be memory such as FRAM, ROM, PROM, EPROM, EEPROM, Flashmemory, magnetic surface memory, optical disk, or CD-ROM; or may be a variety of devices including one or any combination of the above memories, such as a mobile phone, computer, tablet device, personal digital assistant, etc.
An embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, performs:
receiving first notification information sent by a queue service program, wherein the first notification information carries subject messages subscribed by application programs corresponding to the queue service program;
and when the data synchronization node in the block chain network completes data synchronization, the data synchronization node responds to the first notification information and pushes target data to the queue service program so as to realize that the target data is matched with the subject message carried by the first notification information.
Fig. 14 is an optional component diagram of the data processing apparatus according to the embodiment of the present invention, and as shown in fig. 14, the data processing apparatus 1400 may be an apparatus with a data processing function, which is applied to a queue service program. The data processing apparatus 1400 shown in fig. 14 includes: at least one processor 1401, memory 1402, at least one network interface 1404, and a user interface 1403. The various components of the data processing device 1400 are coupled together by a bus system 1405. It will be appreciated that bus system 1405 is used to enable communications among the components connected. The bus system 1405 includes a power bus, a control bus, and a status signal bus, in addition to the data bus. For clarity of illustration, however, the various buses are labeled as bus system 1405 in fig. 14.
User interface 1403 may include, among other things, a display, a keyboard, a mouse, a trackball, a click wheel, keys, buttons, a touch pad, or a touch screen.
It will be appreciated that the memory 1402 can be either volatile memory or nonvolatile memory, and can include both volatile and nonvolatile memory. The memory 1402 described with respect to embodiments of the present invention is intended to comprise these and any other suitable types of memory.
The memory 1402 in the embodiment of the present invention is used to store various types of data included in the storage information to support the operation of the data processing apparatus 1400. Examples of such data include: any computer programs for operating on the data processing apparatus 1400, such as an operating system 14021 and application programs 14022; transaction data, user information, intelligent contracts, etc. The operating system 14021 includes various system programs, such as a framework layer, a core library layer, a driver layer, and the like, for implementing various basic services and processing hardware-based tasks. The application 14022 may contain various applications such as a client with a data processing function, a Media Player (Media Player), a Browser (Browser), and the like, for implementing various application services including passing through the data processing program. A program for implementing the data processing method according to the embodiment of the present invention may be included in the application 14022.
The methods disclosed in the embodiments of the present invention described above may be applied to the processor 1401, or may be implemented by the processor 1401. Processor 1401 may be an integrated circuit chip having signal processing capabilities. In implementation, the steps of the above method may be performed by operations in the form of hardware integrated logic circuits or software in the processor 1401. The Processor 1401 may be a general purpose Processor, a Digital Signal Processor (DSP), or other programmable logic device, discrete gate or transistor logic device, discrete hardware components, etc. Processor 1401 may implement or perform the methods, steps, and logic blocks disclosed in embodiments of the present invention. A general purpose processor may be a microprocessor or any conventional processor or the like. The steps of the method disclosed by the embodiment of the invention can be directly implemented by a hardware decoding processor, or can be implemented by combining hardware and software modules in the decoding processor. The software modules may be located in a storage medium located in memory 1402, where the processor 1401 reads the information in memory 1402 and in combination with its hardware performs the steps of the method described previously.
In an exemplary embodiment, the data processing Device 1400 may be implemented by one or more Application Specific Integrated Circuits (ASICs), DSPs, Programmable logic devices (P L D, Programmable L) Complex Programmable logic devices (CP L D, Complex Programmable L) devices, Field Programmable Gate Arrays (FPGAs), general purpose processors, controllers, Micro Controllers (MCUs), microprocessors (microprocessors), or other electronic components for performing the object data processing method.
In an exemplary embodiment, the present invention further provides a computer readable storage medium, such as the memory 1402 comprising a computer program, which is executable by the processor 1401 of the data processing apparatus 1400 to perform the steps of the aforementioned method. The computer readable storage medium may be memory such as FRAM, ROM, PROM, EPROM, EEPROM, Flashmemory, magnetic surface memory, optical disk, or CD-ROM; or may be a variety of devices including one or any combination of the above memories, such as a mobile phone, computer, tablet device, personal digital assistant, etc.
An embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, performs:
receiving second notification information sent by an application program, wherein the second notification information carries a topic message subscribed by the program;
analyzing the second notification information to generate first notification information carrying a subject message;
sending the generated first notification information to a data synchronization node of the blockchain network;
receiving target data pushed by the data synchronization node;
pushing the received target data to the application to achieve matching of the target data with the application.
Fig. 15 is an alternative block chain service system according to an embodiment of the present invention, and as shown in fig. 15, the block chain service system 1500 may be a system with data processing and transmission functions. The block chain service system 1500 shown in fig. 15 includes: at least one processor 1501, memory 1502, at least one network interface 1504, and a user interface 1503. The various components in the block chain service system 1500 are coupled together by a bus system 1505. It is understood that bus system 1505 is used to enable communications among the components by way of connections. Bus system 1505 includes a power bus, a control bus, and a status signal bus, in addition to a data bus. For clarity of illustration, however, the various buses are labeled as bus system 1505 in fig. 15.
The user interface 1503 may include a display, a keyboard, a mouse, a trackball, a click wheel, a key, a button, a touch pad, a touch screen, or the like, among others.
It will be appreciated that the memory 1502 can be either volatile memory or nonvolatile memory, or can include both volatile and nonvolatile memory. The memory 1502 described in connection with the embodiments of the invention is intended to comprise these and any other suitable types of memory.
Memory 1502 in embodiments of the present invention is used to store various types of data, including locker information, to support the operation of blockchain services system 1500. Examples of such data include: any computer programs for operating on the blockchain service system 1500, such as an operating system 15021 and application programs 15022; transaction data, user information, intelligent contracts, etc. The operating system 15021 contains various system programs, such as a framework layer, a core library layer, a driver layer, and the like, for implementing various basic services and processing hardware-based tasks. The application 15022 may contain various applications such as a client with a data processing function, a Media Player (Media Player), a Browser (Browser), etc. for implementing various application services including passing through the data processing program. A program for implementing the data processing method according to the embodiment of the present invention may be included in the application program 15022.
The method disclosed in the above embodiments of the present invention may be applied to the processor 1501 or implemented by the processor 1501. Processor 1501 may be an integrated circuit chip having signal processing capabilities. In implementation, the steps of the above method may be performed by integrated logic circuits of hardware or operations in the form of software in the processor 1501. The Processor 1501 described above may be a general purpose Processor, a Digital Signal Processor (DSP), or other programmable logic device, discrete gate or transistor logic device, discrete hardware components, or the like. Processor 1501 may implement or perform the methods, steps, and logic blocks disclosed in embodiments of the present invention. A general purpose processor may be a microprocessor or any conventional processor or the like. The steps of the method disclosed by the embodiment of the invention can be directly implemented by a hardware decoding processor, or can be implemented by combining hardware and software modules in the decoding processor. The software modules may be located in a storage medium located in the memory 1502 and the processor 1501 reads the information in the memory 1502 and in conjunction with its hardware performs the steps of the method described previously.
In an exemplary embodiment, the data processing apparatus 1500 may be implemented by one or more Application Specific Integrated Circuits (ASICs), DSPs, Programmable logic devices (P L D, Programmable L) Complex Programmable logic devices (CP L D, Complex Programmable L) devices, Field Programmable Gate Arrays (FPGAs), general purpose processors, controllers, Micro Controllers (MCUs), microprocessors (microprocessors), or other electronic components for performing the object data processing method.
In an exemplary embodiment, the present invention further provides a computer readable storage medium, such as the memory 1502 including a computer program, which can be executed by the processor 1501 of the blockchain service system 1500 to implement the steps of the aforementioned method. The computer readable storage medium can be Memory such as FRAM, ROM, PROM, EPROM, EEPROM, Flash Memory, magnetic surface Memory, optical disk, or CD-ROM; or may be a variety of devices including one or any combination of the above memories, such as a mobile phone, computer, tablet device, personal digital assistant, etc.
An embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, performs:
the block chain network receives third notification information sent by an application program through a queue service program, wherein the third notification information carries subject information subscribed by the application program;
and when the data synchronization node in the block chain network completes data synchronization, the data synchronization node responds to the third notification information and pushes target data to the application program so as to realize that the target data is matched with the theme message carried by the third notification information.
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, embodiments of the present invention may take the form of a hardware embodiment, a software embodiment, or an embodiment combining software and hardware aspects. Furthermore, embodiments of the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including magnetic disk storage, optical storage, and the like) having computer-usable program code embodied in the medium.
Embodiments of the present invention are 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 operations. These computer programs 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 operations performed by the processor of the computer or other programmable data processing apparatus produce means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program operations 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 operations stored in the computer-readable memory produce an article of manufacture including operating means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program operations 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 operations executed 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.
The above description is only exemplary of the present invention and should not be taken as limiting the scope of the present invention, and any modifications, equivalents, improvements, etc. that are within the spirit and principle of the present invention should be included in the present invention.

Claims (22)

1. A data processing method is applied to a block chain network, and is characterized by comprising the following steps:
receiving first notification information sent by a queue service program, wherein the first notification information carries subject messages subscribed by application programs corresponding to the queue service program;
and when the data synchronization node in the block chain network completes data synchronization, the data synchronization node responds to the first notification information and pushes target data to the queue service program so as to realize that the target data is matched with the subject message carried by the first notification information.
2. The method of claim 1, wherein the data synchronization node pushes the target data to the queue service in response to the first notification message, comprising:
the data synchronization node analyzes the theme message carried by the first notification information;
and according to the analyzed theme message, carrying out serialization processing on the data stored in the data synchronization node to form target data to be pushed.
3. The method according to claim 2, wherein the serializing the data stored by the data synchronization node according to the parsed subject message to form target data to be pushed comprises:
determining the priority of different theme messages in the first notification information according to the analyzed theme messages;
determining the processing sequence of different target data based on the determined priorities of different subject messages;
and sequentially carrying out serialization processing on the data stored by the data synchronization node based on the processing sequence of the different target data to form target data pushed to different subject messages of the queue service program.
4. The method according to claim 2, wherein the serializing the data stored by the data synchronization node according to the parsed subject message to form target data to be pushed comprises:
and rewriting the data stored by the data synchronization node according to the analyzed theme message to form target data matched with the application program.
5. The method of claim 1, further comprising:
and the data synchronization node acquires the blocks generated by the adjacent nodes in the block chain network so as to update the block chain data stored by the data synchronization node.
6. The method of claim 5, further comprising:
checking the blocks generated by the acquired adjacent nodes in the block chain network;
when the data passes the verification, storing the acquired data in the block in a distributed storage system corresponding to the data synchronization node;
and receiving a hash value sent by the distributed network, wherein the hash value is used for representing the storage position of the data to be stored in the distributed network.
7. A data processing method applied to a queue service program is characterized by comprising the following steps:
receiving second notification information sent by an application program, wherein the second notification information carries a topic message subscribed by the program;
analyzing the second notification information to generate first notification information carrying a subject message;
sending the generated first notification information to a data synchronization node of the blockchain network;
receiving target data pushed by the data synchronization node;
pushing the received target data to the application to achieve matching of the target data with the application.
8. A data processing method applied to a block chain service system is characterized by comprising the following steps:
the block chain network receives third notification information sent by an application program through a queue service program, wherein the third notification information carries subject information subscribed by the application program;
and when the data synchronization node in the block chain network completes data synchronization, the data synchronization node responds to the third notification information and pushes target data to the application program so as to realize that the target data is matched with the theme message carried by the third notification information.
9. A data processing apparatus for use in a blockchain network, the apparatus comprising:
the system comprises a first data transmission module, a first data transmission module and a second data transmission module, wherein the first data transmission module is used for receiving first notification information sent by a queue service program, and the first notification information carries subject messages subscribed by application programs corresponding to the queue service program;
and the first data processing module is used for responding to the first notification information and pushing target data to the queue service program so as to realize that the target data is matched with the theme message carried by the first notification information.
10. The apparatus of claim 9,
the first data processing module is used for analyzing the theme message carried by the first notification information;
and the first data processing module is used for carrying out serialization processing on the data stored in the data synchronization node according to the analyzed theme message to form target data to be pushed.
11. The apparatus of claim 10,
the first data processing module is used for determining the priority of different theme messages in the first notification information according to the analyzed theme messages;
the first data processing module is used for determining the processing sequence of different target data based on the determined priorities of different subject messages;
and the first data processing module is used for sequentially carrying out serialization processing on the data stored by the data synchronization node based on the processing sequence of the different target data to form target data pushed to different subject messages of the queue service program.
12. The apparatus of claim 10,
and the first data processing module is used for rewriting the data stored by the data synchronization node according to the analyzed theme message so as to form target data matched with the application program.
13. The apparatus of claim 9,
the first data processing module is configured to acquire a block generated by an adjacent node in the blockchain network, so as to update blockchain data stored in the data synchronization node.
14. The apparatus of claim 9, further comprising:
the checking module is used for checking the blocks generated by the adjacent nodes in the acquired block chain network;
the first data processing module is configured to, when the check is passed, store the data in the acquired block in a distributed storage system corresponding to the data synchronization node;
the first data transmission module is configured to receive a hash value sent by the distributed network, where the hash value is used to characterize a storage location of the data to be stored in the distributed network.
15. A data processing apparatus for use in a queue service, the apparatus comprising:
the second data transmission module is used for receiving second notification information sent by an application program, wherein the second notification information carries a topic message subscribed by the program;
the second data processing module is used for analyzing the second notification information and generating first notification information carrying the theme message;
the second data processing module is used for sending the generated first notification information to a data synchronization node of the block chain network;
the second data transmission module is used for receiving the target data pushed by the data synchronization node;
and the second data transmission module is used for pushing the received target data to the application program so as to realize the matching of the target data and the application program.
16. A system for providing blockchain services, the system comprising:
the queue service program module is used for receiving third notification information sent by an application program, wherein the third notification information carries a theme message subscribed by the application program;
and the block chain network module is used for responding to the third notification information and pushing target data to the application program so as to realize that the target data is matched with the theme message carried by the third notification information.
17. A data processing apparatus, comprising:
a memory for storing executable instructions;
a processor for implementing the data processing method of any one of claims 1 to 6 when executing executable instructions stored in the memory.
18. A storage medium storing executable instructions for causing a processor to perform the data processing method of any one of claims 1 to 6 when executed.
19. A data processing apparatus, characterized in that the apparatus comprises:
a processor and a memory for storing executable instructions capable of running on the processor,
wherein the processor is configured to execute the executable instructions to perform the following operations:
receiving second notification information sent by an application program, wherein the second notification information carries a topic message subscribed by the program;
analyzing the second notification information to generate first notification information carrying a subject message;
sending the generated first notification information to a data synchronization node of the blockchain network;
receiving target data pushed by the data synchronization node;
pushing the received target data to the application to achieve matching of the target data with the application.
20. A computer-readable storage medium storing executable instructions, wherein the executable instructions when executed by a processor implement the following operations:
receiving second notification information sent by an application program, wherein the second notification information carries a topic message subscribed by the program;
analyzing the second notification information to generate first notification information carrying a subject message;
sending the generated first notification information to a data synchronization node of the blockchain network;
receiving target data pushed by the data synchronization node;
pushing the received target data to the application to achieve matching of the target data with the application.
21. A blockchain service system, the blockchain service system comprising:
a processor and a memory for storing executable instructions capable of running on the processor,
wherein the processor is configured to execute the executable instructions to perform the following operations:
the block chain network receives third notification information sent by an application program through a queue service program, wherein the third notification information carries subject information subscribed by the application program;
and when the data synchronization node in the block chain network completes data synchronization, the data synchronization node responds to the third notification information and pushes target data to the application program so as to realize that the target data is matched with the theme message carried by the third notification information.
22. A computer-readable storage medium storing executable instructions, wherein the executable instructions when executed by a processor implement the following operations:
the block chain network receives third notification information sent by an application program through a queue service program, wherein the third notification information carries subject information subscribed by the application program;
and when the data synchronization node in the block chain network completes data synchronization, the data synchronization node responds to the third notification information and pushes target data to the application program so as to realize that the target data is matched with the theme message carried by the third notification information.
CN201910067672.7A 2019-01-24 2019-01-24 Data processing method, device, block chain service system and storage medium Pending CN111475309A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910067672.7A CN111475309A (en) 2019-01-24 2019-01-24 Data processing method, device, block chain service system and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910067672.7A CN111475309A (en) 2019-01-24 2019-01-24 Data processing method, device, block chain service system and storage medium

Publications (1)

Publication Number Publication Date
CN111475309A true CN111475309A (en) 2020-07-31

Family

ID=71743878

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910067672.7A Pending CN111475309A (en) 2019-01-24 2019-01-24 Data processing method, device, block chain service system and storage medium

Country Status (1)

Country Link
CN (1) CN111475309A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112347520A (en) * 2020-11-11 2021-02-09 树根互联技术有限公司 Data processing method and device
CN113419761A (en) * 2021-06-24 2021-09-21 广州欢网科技有限责任公司 Method and system for releasing sp/cp operator content injection work
CN113986519A (en) * 2021-12-29 2022-01-28 深圳市毕美科技有限公司 Data scheduling processing method, device, equipment and storage medium
CN117112528A (en) * 2023-10-20 2023-11-24 北京乐讯科技有限公司 Method and system for optimizing data storage in Filecoin

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106453377A (en) * 2016-10-28 2017-02-22 中金云金融(北京)大数据科技股份有限公司 Intelligent monitoring system and method for distributed network based on block chain
US20170192994A1 (en) * 2016-01-05 2017-07-06 The grät Network, PBC Systems and methods concerning tracking models for digital interactions
CN107239479A (en) * 2017-03-28 2017-10-10 阿里巴巴集团控股有限公司 A kind of method and device of data storage and inquiry based on block chain
CN107562775A (en) * 2017-07-14 2018-01-09 阿里巴巴集团控股有限公司 A kind of data processing method and equipment based on block chain
CN108304267A (en) * 2018-01-31 2018-07-20 中科边缘智慧信息科技(苏州)有限公司 The multi-source data of highly reliable low-resource expense draws the method for connecing
CN108628881A (en) * 2017-03-20 2018-10-09 北京京东尚科信息技术有限公司 Method of data synchronization and device
CN108846753A (en) * 2018-06-06 2018-11-20 北京京东尚科信息技术有限公司 Method and apparatus for handling data
CN109032821A (en) * 2018-08-27 2018-12-18 百度在线网络技术(北京)有限公司 Theme message processing method, device, equipment and storage medium
CN109067810A (en) * 2018-10-22 2018-12-21 中链科技有限公司 A kind of distributed message guard method and protective device based on block chain
US20190018887A1 (en) * 2017-04-12 2019-01-17 Vijay K. Madisetti Method and System for Tuning Blockchain Scalability, Decentralization, and Security for Fast and Low-Cost Payment and Transaction Processing

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20170192994A1 (en) * 2016-01-05 2017-07-06 The grät Network, PBC Systems and methods concerning tracking models for digital interactions
CN106453377A (en) * 2016-10-28 2017-02-22 中金云金融(北京)大数据科技股份有限公司 Intelligent monitoring system and method for distributed network based on block chain
CN108628881A (en) * 2017-03-20 2018-10-09 北京京东尚科信息技术有限公司 Method of data synchronization and device
CN107239479A (en) * 2017-03-28 2017-10-10 阿里巴巴集团控股有限公司 A kind of method and device of data storage and inquiry based on block chain
US20190018887A1 (en) * 2017-04-12 2019-01-17 Vijay K. Madisetti Method and System for Tuning Blockchain Scalability, Decentralization, and Security for Fast and Low-Cost Payment and Transaction Processing
CN107562775A (en) * 2017-07-14 2018-01-09 阿里巴巴集团控股有限公司 A kind of data processing method and equipment based on block chain
CN108304267A (en) * 2018-01-31 2018-07-20 中科边缘智慧信息科技(苏州)有限公司 The multi-source data of highly reliable low-resource expense draws the method for connecing
CN108846753A (en) * 2018-06-06 2018-11-20 北京京东尚科信息技术有限公司 Method and apparatus for handling data
CN109032821A (en) * 2018-08-27 2018-12-18 百度在线网络技术(北京)有限公司 Theme message processing method, device, equipment and storage medium
CN109067810A (en) * 2018-10-22 2018-12-21 中链科技有限公司 A kind of distributed message guard method and protective device based on block chain

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
魏琴 等: "《数融未来 图解大数据+产业融合》", 31 May 2018, 贵州人民出版社 *

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112347520A (en) * 2020-11-11 2021-02-09 树根互联技术有限公司 Data processing method and device
CN113419761A (en) * 2021-06-24 2021-09-21 广州欢网科技有限责任公司 Method and system for releasing sp/cp operator content injection work
CN113986519A (en) * 2021-12-29 2022-01-28 深圳市毕美科技有限公司 Data scheduling processing method, device, equipment and storage medium
CN117112528A (en) * 2023-10-20 2023-11-24 北京乐讯科技有限公司 Method and system for optimizing data storage in Filecoin
CN117112528B (en) * 2023-10-20 2024-01-05 北京乐讯科技有限公司 Method and system for optimizing data storage in Filecoin

Similar Documents

Publication Publication Date Title
US10790965B1 (en) Tiered distributed ledger technology (DLT) in a network function virtualization (NFV) core network
KR101778768B1 (en) METHOD OF CONTROLLING IoT DEVICE AND IoT DEVICE CONTROL SYSTEM FOR PERFORMING THE SAME
CN111475309A (en) Data processing method, device, block chain service system and storage medium
CN111324446A (en) Multi-access edge computing node and method for deploying distributed accounting application
CN111475538A (en) Data processing method, device and storage medium
CN110838065A (en) Transaction data processing method and device
EP4216077A1 (en) Blockchain network-based method and apparatus for data processing, and computer device
CN111986764B (en) Medical data sharing method, device, terminal and storage medium based on blockchain
CN111080295A (en) Block chain-based electronic contract processing method and equipment
US11917088B2 (en) Integrating device identity into a permissioning framework of a blockchain
CN103416021A (en) System for enabling digital signature auditing
CN111488372A (en) Data processing method, device and storage medium
CN112291372A (en) Asynchronous posting method, device, medium and electronic equipment for block chain
CN111478764A (en) Data processing method, node and storage medium in block chain network
Chen et al. TrustBuilder: A non-repudiation scheme for IoT cloud applications
CN112766998A (en) Data processing method and device for business activities
CN109711840B (en) Transaction data processing method and device and storage medium
CN110708390A (en) Data processing method, device, apparatus and medium based on inter-node data sharing
CN113301163B (en) Service processing method, system, electronic device and storage medium
Saquib et al. A Resource-Efficient Smart Contract for Privacy Preserving Smart Home Systems
CN112291321A (en) Service processing method, device and system
CN112860805A (en) Block chain data interaction method and system
US11818206B2 (en) Visibility of digital assets at channel level
CN109818965B (en) Personal identity verification device and method
US20180248891A1 (en) Content management based on spatial and temporal information

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
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20200731