WO2023088135A1 - Data communication method and apparatus thereof, storage medium and program product - Google Patents
Data communication method and apparatus thereof, storage medium and program product Download PDFInfo
- Publication number
- WO2023088135A1 WO2023088135A1 PCT/CN2022/130609 CN2022130609W WO2023088135A1 WO 2023088135 A1 WO2023088135 A1 WO 2023088135A1 CN 2022130609 W CN2022130609 W CN 2022130609W WO 2023088135 A1 WO2023088135 A1 WO 2023088135A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- information
- baas platform
- synchronization
- network
- blockchain
- Prior art date
Links
- 238000004891 communication Methods 0.000 title claims abstract description 110
- 238000000034 method Methods 0.000 title claims abstract description 101
- 238000012545 processing Methods 0.000 claims description 42
- 238000004590 computer program Methods 0.000 claims description 22
- 230000015654 memory Effects 0.000 claims description 19
- 238000012795 verification Methods 0.000 claims description 8
- 238000004806 packaging method and process Methods 0.000 claims description 3
- 238000007726 management method Methods 0.000 description 26
- 230000005540 biological transmission Effects 0.000 description 11
- 238000010586 diagram Methods 0.000 description 9
- 230000008520 organization Effects 0.000 description 8
- 230000008569 process Effects 0.000 description 7
- 238000005538 encapsulation Methods 0.000 description 5
- 230000006855 networking Effects 0.000 description 5
- 230000006870 function Effects 0.000 description 4
- 238000005516 engineering process Methods 0.000 description 3
- 230000007246 mechanism Effects 0.000 description 3
- 230000001360 synchronised effect Effects 0.000 description 3
- 238000013500 data storage Methods 0.000 description 2
- 239000004744 fabric Substances 0.000 description 2
- 238000012544 monitoring process Methods 0.000 description 2
- 230000006978 adaptation Effects 0.000 description 1
- 238000012937 correction Methods 0.000 description 1
- 238000007667 floating Methods 0.000 description 1
- 238000010295 mobile communication Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
- 230000007723 transport mechanism Effects 0.000 description 1
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L43/00—Arrangements for monitoring or testing data switching networks
- H04L43/10—Active monitoring, e.g. heartbeat, ping or trace-route
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L63/00—Network architectures or network communication protocols for network security
- H04L63/08—Network architectures or network communication protocols for network security for authentication of entities
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L63/00—Network architectures or network communication protocols for network security
- H04L63/20—Network architectures or network communication protocols for network security for managing network security; network security policies in general
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/10—Protocols in which an application is distributed across nodes in the network
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/10—Protocols in which an application is distributed across nodes in the network
- H04L67/1095—Replication or mirroring of data, e.g. scheduling or transport for data synchronisation between network nodes
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
- H04L9/40—Network security protocols
Definitions
- the present application relates to the field of data cross-platform communication, such as a data communication method and its device, storage medium, and program product.
- blockchain cloud service providers can only provide a unified platform for different users to access and use.
- Block Chain as a Service BaaS
- Embodiments of the present application provide a data communication method and device thereof, a storage medium, and a program product.
- the embodiment of the present application provides a data communication method, which is applied to the first BaaS platform.
- the data communication method includes: deploying a blockchain network; sending invitation information to the second BaaS platform, and the invitation information uses To invite the blockchain node of the second BaaS platform to enter the blockchain network; receive the feedback information sent by the second BaaS platform according to the invitation information; when the feedback information represents the second BaaS platform
- the block chain node agrees to join the block chain network, and the block chain node of the second BaaS platform is added to the block chain network; through the block chain network and the second BaaS platform data communication.
- the embodiment of the present application also provides a data communication device, including: a memory, a processor, and a computer program stored on the memory and operable on the processor, and the computer program is implemented when the processor executes the computer program.
- a data communication device including: a memory, a processor, and a computer program stored on the memory and operable on the processor, and the computer program is implemented when the processor executes the computer program. Data communication method as above.
- the embodiment of the present application further provides a computer-readable storage medium storing computer-executable instructions, and the computer-executable instructions are used to execute the above data communication method.
- the embodiment of the present application also provides a computer program product, including computer programs or computer instructions, the computer programs or computer instructions are stored in a computer-readable storage medium, and the processor of the computer device reads the computer program from the computer-readable storage medium. Taking the computer program or computer instruction, the processor executes the computer program or computer instruction, so that the computer device executes the above data communication method.
- FIG. 1 is a schematic structural diagram of a first BaaS platform for performing a data communication method provided by an embodiment of the present application
- Fig. 2 is a schematic diagram of the "create blockchain network” interface provided by an embodiment of the present application.
- Fig. 3 is a schematic diagram of the function of the network management module provided by an embodiment of the present application.
- FIG. 4 is a schematic diagram of a cross-platform communication scenario between tenant A and tenant B provided by an embodiment of the present application
- Fig. 5 is a schematic structural diagram of a message center module provided by an embodiment of the present application.
- FIG. 6 is a flowchart of a first data communication method provided by an embodiment of the present application.
- FIG. 7 is a flowchart of an example method of step S610 in FIG. 6;
- FIG. 8 is a flowchart of an exemplary method of step S620 in FIG. 6;
- FIG. 9 is a flowchart of a second data communication method provided by an embodiment of the present application.
- FIG. 10 is a flowchart of an exemplary method of step S910 in FIG. 9;
- FIG. 11 is a schematic diagram of an example of active synchronization provided by an embodiment of the present application.
- FIG. 12 is a flowchart of another exemplary method of step S910 in FIG. 9;
- FIG. 13 is a schematic diagram of an example of heartbeat synchronization provided by an embodiment of the present application.
- FIG. 14 is a flowchart of a third data communication method provided by an embodiment of the present application.
- FIG. 15 is a flowchart of a fourth data communication method provided by an embodiment of the present application.
- FIG. 16 is a flowchart of an example method of step S1310 in FIG. 15;
- FIG. 17 is a flowchart of another exemplary method of step S1310 in FIG. 15;
- Fig. 18 is a schematic structural diagram of a data communication device provided by an embodiment of the present application.
- the present application provides a data communication method and its device, storage medium, and program product.
- a blockchain network is deployed, and then a blockchain node for inviting the second BaaS platform to enter the blockchain network is sent to the second BaaS platform.
- the invitation information of the second BaaS platform and then receive the feedback information sent by the second BaaS platform according to the invitation information. If the feedback information indicates that the blockchain node of the second BaaS platform agrees to join the blockchain network, the blockchain node of the second BaaS platform will join
- the blockchain network created by the first BaaS platform data communication between the first BaaS platform and the second BaaS platform is carried out. Cooperative networking between different regions enables data exchange and resource sharing between different cloud platforms to achieve cross-platform communication.
- FIG. 1 is a schematic structural diagram of a first BaaS platform 100 for performing a data communication method provided by an embodiment of the present application.
- the first BaaS platform 100 includes a blockchain underlying engine module 130, an area management module 110, a network management module 120, and a message center module 140, wherein the network management module 120 is connected to the blockchain underlying engine module respectively.
- the module 130, the area management module 110, and the message center module 140 are connected by communication.
- the blockchain underlying engine module 130 can implement the engine based on the consortium chain, wherein the consortium chain includes open source components such as Hyperledger Fabric (super ledger), Fisco Bcos (financial version of the blockchain underlying platform).
- the consortium chain is usually a block chain jointly managed by several institutions, each of which runs one or more nodes, and the data in it only allows different institutions in the system to read, write and send transactions. And work together to record transaction data. Every node participating in the blockchain system is licensed, and unlicensed nodes cannot be connected to the system.
- the consortium chain operates in an authorized consortium chain mode, which mainly includes three main bodies: the first category is the founding committee, the second category is the consortium node group participating in block generation, and the third category is the consortium chain witnesses.
- the area management module 110 is mainly responsible for registering and collecting information in different areas for use in subsequent networking.
- the information in different areas includes parameter names, data types, and information that needs to be noted, and the parameter names include domain names, addresses, and judging whether It is a local domain, etc., and the data types include integer, floating point, string, Boolean, etc., and there is no specific limitation here.
- the domain configuration is shown in Table 1 below, which includes parameter names, data types, optional items, and remark items, where the content in the optional items indicates whether to set the corresponding parameters.
- the area management module 110 can automatically discover the area information of the platform.
- the functions of the network management module 120 may include network deployment, node management, invitation to join the network, etc., which are not specifically limited here.
- users can easily and conveniently deploy a blockchain network with one click through the "Create Blockchain Network” interface.
- the "Create Blockchain Network” interface includes the "Blockchain Network Name” item, the “Blockchain Network Description” item, the “Blockchain Network Type " project, “consensus strategy” project, “security mechanism” project, "choice domain” project, “network engine” project, “engine version” project, “state database” project, “block storage” project, “CA (Certificate Authority , electronic certification) service” project and “peer (level) node organization”, when deploying the blockchain network, you can set the relevant parameters of the blockchain network through this interface, for example, in the "blockchain network name” Set the network name (such as XX network) in the project, fill in the relevant introduction information for the set blockchain network in
- the network management module 120 can select the underlying engine of the blockchain in the underlying engine module 130 of the blockchain to create a blockchain network, such as network A.
- the regional management module 110 can Configured regional information, network platform nodes in different regions, such as the first BaaS platform 100 and the second BaaS platform, access this network; at the same time, the network management module 120 can also invite tenants of other platforms in the created network Join the blockchain network, say Tenant A and Tenant B. Tenants can interact through the blockchain network, thus shielding the complex issues of mutual communication between the underlying engines of the blockchain and simplifying user operations.
- tenant A and tenant B respectively deploy a set of BaaS platforms locally.
- Tenant A and tenant B perform regional registration through the regional management module.
- Tenant A selects the underlying engine of the blockchain.
- the blockchain network is deployed on the BaaS platform, and then tenant A sends a message to tenant B in other domains to invite to join the network.
- the cross-platform invitation message will be sent through tenant A's local message center module, and tenant B will be in the local message center.
- the module receives the invitation notification sent by tenant A, chooses to agree to join the blockchain network, updates the network configuration, joins the organization and all nodes under the organization in the blockchain network, and synchronizes network information to other domains; or, the tenant B applies to join the blockchain network of tenant A, and sends an application notification from the local message center module.
- tenant B After the approval of tenant A, tenant B is notified to join the blockchain network. After receiving the notification, tenant B updates the network configuration. The organization and all nodes under the organization are added to the blockchain network, which enables different tenants to share and exchange data and resources on the same blockchain network under cross-platform conditions.
- the message center module 140 includes an interface layer 141 , a push pool 144 , a heartbeat pool 142 , and a communication layer 143 .
- the functions of this module include cross-platform message synchronization, etc., which are not specifically limited here.
- message synchronization mainly adopts the master-slave synchronization method.
- the BaaS platform initiated by the network is the master BaaS platform
- the BaaS platform that joins the network is the slave BaaS platform.
- Network configuration changes are synchronized from the master BaaS platform to the slave BaaS platform.
- all network configuration data can also be obtained from the main BaaS platform from the BaaS platform.
- the network management module in the main BaaS platform issues a message to the message center module 140 in the main BaaS platform, and the interface layer 141 of the message center module 140 receives the message, and the message received through the interface layer 141 will be released.
- the push pool 144 (or heartbeat pool 142) packs the message in the push queue according to the rules, and sends it to the communication layer 143 of the network management module , the communication layer 143 sends a message to the destination address according to the destination address, and the destination address receives the message from the communication layer 143 in the BaaS platform, and sends a message to the receiving queue of the push pool 144 (or heartbeat pool 142) in the BaaS platform , then send a message from the push pool 144 (or heartbeat pool 142) in the BaaS platform to the interface layer 141 in the BaaS platform, then from the interface layer 141 in the BaaS platform to the network management module in the BaaS platform, so that Message request distribution processing is performed from the network management module in the BaaS platform.
- the slave BaaS platform can also send a message to obtain all network configuration data to the master BaaS platform.
- the message sending process is
- the architecture of the second BaaS platform may be the same as that of the first BaaS platform, and the second BaaS platform may also include a block chain underlying engine module, a regional management module, a network management module, and a message center module 140, etc. , depends on the actual situation, and no specific limitation is made here.
- the first BaaS platform and application scenarios described in the embodiments of the present application are to more clearly illustrate the technical solutions of the embodiments of the present application, and do not constitute limitations on the technical solutions provided in the embodiments of the present application.
- Those skilled in the art know that as The evolution of the architecture of the first BaaS platform and the emergence of new application scenarios, the technical solutions provided by the embodiments of the present application are also applicable to similar technical problems.
- first BaaS platform shown in Figure 1 and the message center module shown in Figure 5 does not constitute a limitation to the embodiment of the application, and may include more or more Fewer components, or combinations of certain components, or different arrangements of components.
- FIG. 6 is a flowchart of a data communication method provided by an embodiment of the present application.
- the data communication method can be applied to a first BaaS platform, such as the first BaaS platform shown in FIG. 1 .
- the data communication method may include but not limited to step S610, step S620, step S630, step S640 and step S650.
- Step S610 Deploy the blockchain network.
- a blockchain network is deployed, so that data communication with the second BaaS platform can be performed through the blockchain network in subsequent steps.
- Step S620 Send invitation information to the second BaaS platform, where the invitation information is used to invite the blockchain nodes of the second BaaS platform to enter the blockchain network.
- the blockchain network is deployed through step S610, therefore, the first BaaS platform can send invitation information for inviting the blockchain nodes of the second BaaS platform to enter the blockchain network to the second BaaS platform, so that the second BaaS platform The second BaaS platform sends feedback information to the first BaaS platform according to the invitation information.
- Step S630 Receive the feedback information sent by the second BaaS platform according to the invitation information.
- the feedback information sent by the second BaaS platform according to the invitation information can be received, so that the subsequent step S640 can verify the feedback information.
- the information indicates that the blockchain nodes of the second BaaS platform agree to join the blockchain network, and the blockchain nodes of the second BaaS platform are added to the blockchain network.
- the feedback information can be used to express the meaning that the second BaaS platform agrees to join the blockchain network, or it can be used to express the meaning that the second BaaS platform refuses to join the blockchain network. limited.
- Step S640 When the feedback information indicates that the blockchain node of the second BaaS platform agrees to join the blockchain network, join the blockchain node of the second BaaS platform to the blockchain network.
- step S630 since the feedback information is received in step S630, the feedback information can be verified.
- the feedback information indicates that the blockchain node of the second BaaS platform agrees to join the blockchain network
- the second BaaS platform will The blockchain node of the blockchain is added to the blockchain network, so that the subsequent steps can communicate data between the first BaaS platform and the second BaaS platform through the blockchain network.
- Step S650 Perform data communication with the second BaaS platform through the blockchain network.
- step S640 since the second BaaS platform has been added to the blockchain network in step S640, the first BaaS platform and the second BaaS platform can be connected to each other through the blockchain network created by the first BaaS platform. communication.
- step S610 is further described, and step S610 may include but not limited to step S710 , step S720 and step S730 .
- Step S710 Select the target blockchain engine and region.
- the region can be configured in subsequent steps.
- target blockchain engine can be the underlying engine of the blockchain, or other engines, and no specific limitation is set here.
- the target blockchain engine can be implemented based on the consortium chain.
- the target blockchain engine can be implemented by open source components such as Hyperledger Fabric and Fisco Bcos.
- Step S720 Perform configuration processing on the area to obtain area information.
- the area can be configured to obtain area information, so as to obtain the destination address of the second BaaS platform.
- Step S730 Deploy the blockchain network according to the target blockchain engine and regional information.
- step S720 since the target blockchain engine is obtained in step S710 and the region information is configured in step S720, the blockchain network can be deployed according to the target blockchain engine and region information.
- the network management module selects the target blockchain engine and region in the blockchain underlying engine module, and then configures the region to obtain region information, and finally the network
- the management module deploys the blockchain network according to the target blockchain engine and regional information, so that different cloud platforms can interact through the blockchain network, thus shielding the complex issues of mutual communication between the underlying blockchain engines and simplifying the user experience. operate.
- step S620 is further described, and step S620 may include but not limited to step S810 , step S820 and step S830 .
- Step S810 Generate invitation information according to the network information of the blockchain network.
- the network management module generates invitation information according to the network information of the blockchain network, so that the invitation information can be encapsulated in subsequent steps to obtain the encapsulated invitation information.
- the invitation message can be used to express the desire for other BaaS platforms to join the blockchain network. It should also be noted that at the moment when the invitation information is generated, these BaaS platforms and the first BaaS platform do not belong to the same network.
- invitation information may be one or more, depending on the actual situation, which is not specifically limited here.
- Step S820 Encapsulate the invitation information to obtain encapsulated invitation information.
- the message center module can encapsulate the invitation information to obtain the encapsulated invitation information, so as to send the encapsulated invitation information to the second BaaS platform in subsequent steps.
- This step can make the invitation information sent to the destination reliably and accurately.
- the invitation information may be encapsulated according to an encapsulation protocol.
- the invitation information is mapped to the payload of the encapsulation protocol, and then the header of the corresponding protocol is filled to form a data packet of the encapsulation protocol, and the rate adaptation is completed.
- the encapsulation process can be to add the destination address, local address, and some bytes for error correction to the sent data packet. In addition, it can also perform encryption processing, etc., which makes invitation information is more secure and reliable during transmission.
- the encapsulation protocol is a rule that the first BaaS platform and the platform to be sent jointly follow and negotiate.
- Step S830 Send the encapsulated invitation information to the second BaaS platform.
- the message center module can send the encapsulated invitation information to the second BaaS platform, so that the subsequent steps can receive the invitation information sent by the second BaaS platform according to the invitation information. feedback information.
- the network management module can generate invitation information according to the network information of the blockchain network, and then the message center module can encapsulate the invitation information to obtain the encapsulated invitation information, and finally The encapsulated invitation information is sent to the second BaaS platform, so as to prepare for subsequent data communication between the first BaaS platform and the second BaaS platform.
- the message center module of the first BaaS platform will generate an invitation according to the network information of the blockchain network information, and then the interface layer of the message center module sends the invitation information to the push queue of the push pool of the message center module, encapsulates the invitation information according to the rules, and then sends the encapsulated invitation information to the communication of the message center module Layer, through calling protocols, such as grpc (google Remote Procedure Calls, Google Remote Procedure Call) protocol, xml-rpc (XML Remote Procedure Call, XML Remote Procedure Call) protocol or binary-rpc (binary Remote Procedure Call, binary remote procedure call ) protocol, according to the destination address of the second BaaS platform, it is sent to the communication layer of the second BaaS platform, and then the communication layer of the second BaaS platform sends the encapsulated invitation information to the receiving queue of the push pool of the second BaaS platform,
- grpc google Remote Procedure Calls, Google Remote Procedure Call
- xml-rpc XML Remote Procedure
- the data communication method may further include but not limited to step S910.
- Step S910 Perform information synchronization update processing on the second BaaS platform according to the network information of the blockchain network.
- the first BaaS platform since the first BaaS platform has performed data communication with the second BaaS platform through the blockchain network in the above steps, information synchronization can be performed on the second and second BaaS platforms according to the network information of the blockchain network Update processing, which ensures the consistency and reliability of communication between different cloud platforms in the same blockchain network, reducing communication failures and transmission errors.
- the ways of synchronizing and updating may include active synchronization and heartbeat synchronization, etc., which are not specifically limited here.
- step S910 is further described, and step S910 may include but not limited to step S1010 , step S1020 and step S1030 .
- Step S1010 Obtain the first configuration update information according to the network information of the blockchain network.
- the first configuration update information can be obtained according to the network information of the blockchain network, so as to package the first configuration update information in subsequent steps.
- the first configuration update information is configuration information of the first BaaS platform.
- the first configuration update information may include content such as domain name and IP address, which is not specifically limited here.
- Step S1020 Perform packaging processing on the first configuration update information to obtain first synchronization information.
- the first configuration update information can be packaged to obtain the first synchronization message, so that the subsequent steps can send the first synchronization message to the second BaaS platform Information, so that the second BaaS platform performs information synchronization update processing according to the first synchronization information.
- first configuration update information may be packaged periodically, which may be determined according to actual conditions, and is not specifically limited here.
- Step S1030 Send the first synchronization information to the second BaaS platform, so that the second BaaS platform performs information synchronization update processing according to the first synchronization information.
- the first synchronization information can be sent to the second BaaS platform, so that the second BaaS platform performs information synchronization update processing according to the first synchronization information, which ensures the same Consistency and reliability of communication between different cloud platforms in the blockchain network, reducing communication failures and transmission errors.
- the first configuration update information is obtained according to the network information of the blockchain network, and then the first configuration update information is packaged to obtain the first synchronization information, and finally sent to the second
- the second BaaS platform sends the first synchronization information, so that the second BaaS platform performs information synchronization update processing according to the first synchronization information, thereby ensuring the consistency and reliability of communication between different cloud platforms in the same blockchain network and reducing communication glitches and transmission errors.
- the message center module of the first BaaS platform is the first message center module
- the message center module of the second BaaS platform is the second message center module
- the first message center module includes the first message center module A configuration synchronization module and the first push pool
- the second message center module includes the second configuration synchronization module and the second push pool
- the first configuration synchronization module obtains the first configuration update information according to the network information of the block chain network, and sends it to The first push pool
- the first push pool regularly packages the first configuration update information to obtain the first synchronization information
- the first push pool adds the first synchronization information to the push synchronization list through the push message (or the main grpc interface)
- the push synchronization list is sent to the second push pool
- the second push pool notifies the second configuration synchronization module of update synchronization
- the second configuration synchronization module performs synchronization update on the second BaaS platform.
- the second BaaS platform can start monitoring events, obtain the first configuration update information through broadcasting, and perform synchronous updates.
- the second BaaS platform may also obtain the first configuration update information in other ways, such as unicast, multicast, etc., which are not specifically limited here.
- step S910 is further described, and step S910 may include but not limited to step S1110 , step S1120 and step S1130 .
- Step S1110 Receive a first heartbeat synchronization message of the second BaaS platform, where the first heartbeat synchronization message includes current configuration information of the second BaaS platform.
- the message center module receives the first heartbeat synchronization message of the second BaaS platform including the current configuration information of the second BaaS platform, so that subsequent steps can update the current configuration information of the second BaaS platform according to the network information of the blockchain network for comparison.
- the current configuration information of the second BaaS platform may include a configuration list of networks, channels, organizations, nodes, or chaincodes, and the configuration list may include IDs and hash values, which are not specifically limited here.
- Step S1120 Compare and process the current configuration information of the second BaaS platform according to the network information of the blockchain network to obtain second synchronization information.
- the current configuration information of the second BaaS platform can be compared according to the network information of the blockchain network , to obtain the second synchronization information, so as to send the second synchronization information to the second BaaS platform in a subsequent step, so that the second BaaS platform performs information synchronization update processing according to the second synchronization information.
- Step S1130 Send the second synchronization information to the second BaaS platform, so that the second BaaS platform performs information synchronization update processing according to the second synchronization information.
- the second synchronization information can be sent to the second BaaS platform, so that the second BaaS platform performs information synchronization update processing according to the second synchronization information, which ensures the same Consistency and reliability of communication between different cloud platforms in the blockchain network, reducing communication failures and transmission errors.
- the message center module receives the first heartbeat synchronization message of the second BaaS platform including the current configuration information of the second BaaS platform, and then performs the first heartbeat synchronization message according to the network information of the blockchain network.
- the current configuration information of the two BaaS platforms is compared and processed to obtain the second synchronization information, and finally the second synchronization information is sent to the second BaaS platform, so that the second BaaS platform performs information synchronization update processing according to the second synchronization information, ensuring the same block Consistency and reliability of communication between different cloud platforms in the blockchain network, reducing communication failures and transmission errors.
- the message center module of the first BaaS platform is the first message center module
- the message center module of the second BaaS platform is the second message center module
- the first message center module includes the first message center module
- the second message center module includes a second configuration synchronization module and a second push pool
- the second configuration synchronization module encapsulates the current configuration information of the second BaaS platform, and adds it to the first heartbeat
- the first heartbeat synchronization message is then sent to the second push pool
- the second push pool periodically packages the first heartbeat synchronization message, and then periodically passes the slave grpc interface according to the timing task or the message size threshold
- the network information of the first configuration synchronization module is compared with the current configuration information of the first configuration synchronization module, and then the configuration content with differences is added to the second synchronization information of active synchronization.
- the first configuration synchronization module submits the second configuration information to the first push pool.
- the first push pool sends second synchronization information to the second push pool through the main grpc interface, and the second push pool notifies the second configuration synchronization module to update synchronization after receiving the second synchronization information, and the second configuration synchronization module according to the first
- the second synchronization information performs information synchronization update processing.
- the data communication method may further include, but not limited to, step S1210, step S1220, and step S1230.
- Step S1210 Receive the request information sent by the third BaaS platform, the request information is used to indicate that the blockchain nodes of the third BaaS platform apply to join the blockchain network.
- the message center module of the first BaaS platform receives the request information sent by the third BaaS platform to represent the block chain node application of the third BaaS platform to join the block chain network, so that the subsequent steps can respond to the request information Perform verification processing.
- Step S1220 Verify the request information, and when the request information passes the verification, send the notification information of joining the blockchain network to the third BaaS platform, so that the blockchain nodes of the third BaaS platform join the blockchain network according to the notification information .
- the request information since the request information is received in step S1210, the request information can be verified.
- the notification information of joining the blockchain network is sent to the third BaaS platform, so that the third The blockchain nodes of the BaaS platform join the blockchain network according to the notification information, so that the subsequent steps can communicate data between the first BaaS platform and the third BaaS platform through the blockchain network created by the first BaaS platform.
- Step S1230 Perform data communication with the third BaaS platform through the blockchain network.
- step S1220 since the notification information of joining the blockchain network is sent to the third BaaS platform in step S1220, the first BaaS platform and the third BaaS platform are connected through the blockchain network created by the first BaaS platform. data communication.
- the message center module of the first BaaS platform can receive the request information sent by the third BaaS platform to represent the application of the blockchain node of the third BaaS platform to join the blockchain network , and then verify the request information.
- the request information passes the verification, a notification message to join the blockchain network is sent to the third BaaS platform, and finally through the blockchain network created by the first BaaS platform, the first BaaS platform third
- the BaaS platform performs data communication, that is to say, the scheme of the embodiment of the present application can realize collaborative networking between different cloud platforms and different regions, therefore, the scheme of the embodiment of the present application can realize data exchange and communication between different cloud platforms. Resource sharing to achieve cross-platform communication purposes.
- the third BaaS platform puts the request information into the request queue of the heartbeat pool of the third BaaS platform, packs the request queue, sends it to the communication layer of the third BaaS platform, and uses the grpc protocol according to the destination address Send to the communication layer of the first BaaS platform.
- the communication layer of the first BaaS platform After receiving the request information, the communication layer of the first BaaS platform sends it to the receiving queue of the heartbeat pool of the first BaaS platform.
- the receiving queue requests the interface layer of the first BaaS platform to distribute the request information , and then the interface layer sends the request information to the network management module of the first BaaS platform, and the network management module of the first BaaS platform requests information for verification processing.
- the request information passes the verification, it sends the request information to the third BaaS platform to join the blockchain network Notification information, the blockchain node of the third BaaS platform joins the blockchain network according to the notification information, and finally the first BaaS platform performs data communication with the third BaaS platform through the blockchain network.
- the data communication method may further include but not limited to step S1310.
- Step S1310 Perform information synchronization update processing on the third BaaS platform according to the network information of the blockchain network.
- the information synchronization update process can be performed on the third BaaS platform according to the network information of the blockchain network , which ensures the consistency and reliability of communication between different cloud platforms in the same blockchain network, reducing communication failures and transmission errors.
- the ways of synchronizing and updating may include active synchronization and heartbeat synchronization, etc., which are not specifically limited here.
- step S1310 is further described, and step S1310 may include but not limited to step S1410 , step S1420 and step S1430 .
- Step S1410 Obtain the second configuration update information according to the network information of the blockchain network.
- the second configuration update information can be obtained according to the network information of the blockchain network, so as to package the second configuration update information in subsequent steps.
- the second configuration update information is configuration information of the first BaaS platform.
- Step S1420 Packetize the second configuration update information to obtain third synchronization information.
- the second configuration update information can be packaged to obtain a third synchronization message, so that the subsequent steps can send the third synchronization message to the third BaaS platform Information, so that the third BaaS platform performs information synchronization update processing according to the third synchronization information.
- the second configuration update information may be packaged periodically, which may be determined according to actual conditions, and is not specifically limited here.
- Step S1430 Send third synchronization information to the third BaaS platform, so that the third BaaS platform performs information synchronization update processing according to the third synchronization information.
- step S1420 since the third synchronization information is obtained in step S1420, the third synchronization information can be sent to the third BaaS platform, so that the third BaaS platform performs information synchronization update processing according to the third synchronization information, which ensures the same Consistency and reliability of communication between different cloud platforms in the blockchain network, reducing communication failures and transmission errors.
- the second configuration update information is obtained according to the network information of the blockchain network, and then the second configuration update information is packaged to obtain the third synchronization information, and finally sent to the second
- the third BaaS platform sends the third synchronization information, so that the third BaaS platform performs information synchronization update processing according to the third synchronization information, thereby ensuring the consistency and reliability of communication between different cloud platforms in the same blockchain network and reducing communication glitches and transmission errors.
- the message center module of the first BaaS platform is the first message center module
- the message center module of the third BaaS platform is the third message center module
- the first message center module includes the first configuration synchronization module and the second message center module.
- the third message center module includes a third configuration synchronization module and a third push pool
- the first configuration synchronization module obtains the second configuration update information according to the network information of the blockchain network, and sends it to the first push pool
- the second A push pool regularly packages the second configuration update information to obtain the third synchronization information
- the first push pool adds the third synchronization information to the push synchronization list through a push message (or main grpc interface), and then pushes the
- the third synchronization information in the synchronization list is sent to the third push pool, and the third push pool notifies the update synchronization to the third configuration synchronization module, and the third configuration synchronization module performs synchronization update on the third BaaS platform.
- the third BaaS platform can start monitoring events, obtain the second configuration update information by broadcasting, and perform synchronous updates.
- the third BaaS platform may also obtain the second configuration update information in other ways, such as unicast, multicast, etc., which are not specifically limited here.
- step S1310 is further described, and step S1310 may include but not limited to step S1510 , step S1520 and step S1530 .
- Step S1510 Receive a second heartbeat synchronization message of the third BaaS platform, where the second heartbeat synchronization message includes current configuration information of the third BaaS platform.
- the message center module receives the second heartbeat synchronization message of the third BaaS platform including the current configuration information of the third BaaS platform, so that the subsequent steps can update the current configuration information of the third BaaS platform according to the network information of the block chain network for comparison.
- the current configuration information of the third BaaS platform may include a configuration list of networks, channels, organizations, nodes, or chaincodes, and the configuration list may include IDs and hash values, which are not specifically limited here.
- Step S1520 Compare and process the current configuration information of the third BaaS platform according to the network information of the blockchain network to obtain fourth synchronization information.
- step S1510 since the second heartbeat synchronization message including the current configuration information of the third BaaS platform is obtained in step S1510, the current configuration information of the third BaaS platform can be compared according to the network information of the blockchain network , to obtain the fourth synchronization information, so as to send the fourth synchronization information to the third BaaS platform in a subsequent step, so that the third BaaS platform performs information synchronization update processing according to the fourth synchronization information.
- Step S1530 Send fourth synchronization information to the third BaaS platform, so that the third BaaS platform performs information synchronization update processing according to the fourth synchronization information.
- the fourth synchronization information can be sent to the third BaaS platform, so that the third BaaS platform performs information synchronization update processing according to the fourth synchronization information, which ensures the same Consistency and reliability of communication between different cloud platforms in the blockchain network, reducing communication failures and transmission errors.
- the message center module receives the second heartbeat synchronization message of the third BaaS platform including the current configuration information of the third BaaS platform, and then performs the second heartbeat synchronization message according to the network information of the blockchain network.
- the current configuration information of the three BaaS platforms is compared and processed to obtain the fourth synchronization information, and finally the fourth synchronization information is sent to the third BaaS platform, so that the third BaaS platform performs information synchronization update processing according to the fourth synchronization information, ensuring the same block Consistency and reliability of communication between different cloud platforms in the blockchain network, reducing communication failures and transmission errors.
- the message center module of the first BaaS platform is the first message center module
- the message center module of the third BaaS platform is the third message center module
- the first message center module includes the first configuration synchronization module and the second message center module.
- the third message center module includes a third configuration synchronization module and a third push pool
- the third configuration synchronization module encapsulates the current configuration information of the third BaaS platform, and adds it to the second heartbeat synchronization message, and then sends the
- the second heartbeat synchronization message is sent to the third push pool
- the third push pool regularly packs the second heartbeat synchronization message, and then periodically transmits the message from the grpc interface to the first BaaS platform according to the timing task or the message size threshold.
- the first configuration synchronization module sends the second heartbeat synchronization message, and the first push pool forwards it to the first configuration synchronization module of the first BaaS platform.
- the configuration information is compared and processed, and then the configuration content with differences is added to the fourth synchronization information of active synchronization. Then, the first configuration synchronization module submits the fourth synchronization information to the first push pool, and the first push pool passes the main grpc interface The fourth synchronization information is sent to the third push pool, and after receiving the fourth synchronization information, the third push pool notifies the third configuration synchronization module of update synchronization, and the third configuration synchronization module performs information synchronization update processing according to the fourth synchronization information.
- the embodiment of the present application also provides a data communication device 200, as shown in Figure 18, the data communication device 200 includes but is not limited to:
- memory 202 for storing programs
- the processor 201 is configured to execute the program stored in the memory 202.
- the processor 201 executes the program stored in the memory 202, the processor 201 is configured to execute the above data communication method.
- the processor 201 and the memory 202 may be connected through a bus or other means.
- the memory 202 can be used to store non-transitory software programs and non-transitory computer-executable programs, such as the data communication method described in the embodiment of the present application.
- the processor 201 implements the above-mentioned data communication method by running the non-transitory software programs and instructions stored in the memory 202 .
- the memory 202 may include a program storage area and a data storage area, wherein the program storage area may store an operating system and an application program required by at least one function; the data storage area may store and execute the above-mentioned data communication method.
- the memory 202 may include a high-speed random access memory, and may also include a non-transitory memory, such as at least one magnetic disk storage device, a flash memory device, or other non-transitory solid-state storage devices.
- the memory 202 may optionally include memory 202 remotely located relative to the processor 201, and these remote memories may be connected to the processor 201 through a network. Examples of the aforementioned networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.
- the non-transitory software programs and instructions required to realize the above-mentioned data communication method are stored in the memory 202, and when executed by one or more processors 201, the above-mentioned data communication method is executed, for example, the above-described execution in FIG. 6 is executed.
- Method step S1110 to step S1130 in 12 method step S1210 to step S1230 in FIG. 14 , method step S1310 in FIG. 15 , method step S1410 to step S1430 in FIG. 16 and method step S1510 to step S1530 in FIG. 17 .
- An embodiment of the present application also provides a computer-readable storage medium, the computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are executed by a processor or a controller, for example, implemented by the above-mentioned device Execution by a processor in the example can cause the above-mentioned processor to execute the data communication method in the above-mentioned embodiment, for example, execute the method steps S610 to S650 in FIG. 6 and the method steps S710 to S730 in FIG. 7 described above. , method step S810 to step S830 in Fig. 8, method step S910 in Fig. 9, method step S1010 to step S1030 in Fig. 10, method step S1110 to step S1130 in Fig. 12, method step S1210 to step S1130 in Fig. 14 Step S1230, method step S1310 in FIG. 15, method step S1410 to step S1430 in FIG. 16, and method step S1510 to step S1530 in FIG. 17.
- an embodiment of the present application also provides a computer program product, including computer programs or computer instructions, where the computer programs or computer instructions are stored in a computer-readable storage medium, and the processor of the computer device reads the computer program from the computer-readable storage medium.
- the processor executes the computer program or computer instruction, so that the computer device executes the data communication method in the above-mentioned embodiment, for example, executes the method step S610 to step S650 in FIG. 6 described above, and the method in FIG. 7 Method step S710 to step S730, method step S810 to step S830 in Fig. 8, method step S910 in Fig. 9, method step S1010 to step S1030 in Fig.
- method step S1110 to step S1130 in Fig. 12, Fig. 14 The method step S1210 to step S1230 in FIG. 15 , the method step S1310 in FIG. 15 , the method step S1410 to step S1430 in FIG. 16 , and the method step S1510 to step S1530 in FIG. 17 .
- the embodiment of this application includes: deploying a blockchain network; sending invitation information to the second BaaS platform, the invitation information is used to invite the blockchain nodes of the second BaaS platform to enter the blockchain network; receiving the second BaaS platform according to the invitation information sent Feedback information; when the feedback information indicates that the blockchain node of the second BaaS platform agrees to join the blockchain network, the blockchain node joined by the second BaaS platform will be added to the blockchain network; through the blockchain network and the second BaaS platform for data communication.
- the blockchain network created by the platform communicates data between the first BaaS platform and the second BaaS platform. Data exchange and resource sharing between different cloud platforms to achieve cross-platform communication.
- Computer storage media includes, but is not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital versatile disk (DVD) or other optical disk storage, magnetic cartridges, tape, magnetic disk storage or other magnetic storage devices, or can Any other medium used to store desired information and which can be accessed by a computer.
- communication media typically embodies computer readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transport mechanism, and may include any information delivery media .
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Computer Security & Cryptography (AREA)
- Health & Medical Sciences (AREA)
- Cardiology (AREA)
- General Health & Medical Sciences (AREA)
- Computer Hardware Design (AREA)
- Computing Systems (AREA)
- General Engineering & Computer Science (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
The present application discloses a data communication method and an apparatus thereof, a storage medium and a program product. The data communication method is used in a first blockchain as a service (BaaS) platform, and the data communication method comprises: deploying a blockchain network (S610); sending invitation information to a second BAAS platform, the invitation information being used for inviting a blockchain node of the second BAAS platform to enter the blockchain network (S620); receiving feedback information sent by the second BAAS platform according to the invitation information (S630); when the feedback information represents that the blockchain node of the second BaaS platform agrees to join the blockchain network, adding the blockchain node of the second BaaS platform to the blockchain network (S640); and performing data communication with the second BAAS platform by means of the blockchain network (S650).
Description
相关申请的交叉引用Cross References to Related Applications
本申请基于申请号为202111386056.1、申请日为2021年11月22日的中国专利申请提出,并要求该中国专利申请的优先权,该中国专利申请的全部内容在此引入本申请作为参考。This application is based on a Chinese patent application with application number 202111386056.1 and a filing date of November 22, 2021, and claims the priority of this Chinese patent application. The entire content of this Chinese patent application is hereby incorporated by reference into this application.
本申请涉及数据跨平台通讯领域,例如一种数据通信方法及其装置、存储介质、程序产品。The present application relates to the field of data cross-platform communication, such as a data communication method and its device, storage medium, and program product.
相关技术中,区块链云服务商只能提供一个统一的平台,供不同的用户接入使用。在不同的云平台、不同的地域部署两个或者多个区块链服务(Block Chain as a Service,BaaS)平台,协同组网,实现不同云平台之间的数据交换和资源共享,还没有一个解决方案。In related technologies, blockchain cloud service providers can only provide a unified platform for different users to access and use. Deploy two or more blockchain service (Block Chain as a Service, BaaS) platforms on different cloud platforms and different regions, and coordinate networking to realize data exchange and resource sharing between different cloud platforms. solution.
发明内容Contents of the invention
以下是对本文详细描述的主题的概述。本概述并非是为了限制权利要求的保护范围。The following is an overview of the topics described in detail in this article. This summary is not intended to limit the scope of the claims.
本申请实施例提供了一种数据通信方法及其装置、存储介质、程序产品。Embodiments of the present application provide a data communication method and device thereof, a storage medium, and a program product.
第一方面,本申请实施例提供了一种数据通信方法,应用于第一BaaS平台,所述数据通信方法包括:部署区块链网络;向第二BaaS平台发送邀请信息,所述邀请信息用于邀请所述第二BaaS平台的区块链节点进入所述区块链网络;接收所述第二BaaS平台根据所述邀请信息发送的反馈信息;当所述反馈信息表征所述第二BaaS平台的区块链节点同意加入所述区块链网络,将所述第二BaaS平台的区块链节点加入到所述区块链网络;通过所述区块链网络与所述第二BaaS平台进行数据通信。In the first aspect, the embodiment of the present application provides a data communication method, which is applied to the first BaaS platform. The data communication method includes: deploying a blockchain network; sending invitation information to the second BaaS platform, and the invitation information uses To invite the blockchain node of the second BaaS platform to enter the blockchain network; receive the feedback information sent by the second BaaS platform according to the invitation information; when the feedback information represents the second BaaS platform The block chain node agrees to join the block chain network, and the block chain node of the second BaaS platform is added to the block chain network; through the block chain network and the second BaaS platform data communication.
第二方面,本申请实施例还提供了一种数据通信装置,包括:存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现如上的数据通信方法。In the second aspect, the embodiment of the present application also provides a data communication device, including: a memory, a processor, and a computer program stored on the memory and operable on the processor, and the computer program is implemented when the processor executes the computer program. Data communication method as above.
第三方面,本申请实施例还提供了一种计算机可读存储介质,存储有计算机可执行指令,计算机可执行指令用于执行如上的数据通信方法。In a third aspect, the embodiment of the present application further provides a computer-readable storage medium storing computer-executable instructions, and the computer-executable instructions are used to execute the above data communication method.
第四方面,本申请实施例还提供了一种计算机程序产品,包括计算机程序或计算机指令,计算机程序或计算机指令存储在计算机可读存储介质中,计算机设备的处理器从计算机可读存储介质读取计算机程序或计算机指令,处理器执行计算机程序或计算机指令,使得计算机设备执行如上的数据通信方法。In a fourth aspect, the embodiment of the present application also provides a computer program product, including computer programs or computer instructions, the computer programs or computer instructions are stored in a computer-readable storage medium, and the processor of the computer device reads the computer program from the computer-readable storage medium. Taking the computer program or computer instruction, the processor executes the computer program or computer instruction, so that the computer device executes the above data communication method.
本申请的其它特征和优点将在随后的说明书中阐述,并且,部分地从说明书中变得显而易见,或者通过实施本申请而了解。本申请的目的和其他优点可通过在说明书、权利要求书以及附图中所特别指出的结构来实现和获得。Additional features and advantages of the application will be set forth in the description which follows, and, in part, will be obvious from the description, or may be learned by practice of the application. The objectives and other advantages of the application will be realized and attained by the structure particularly pointed out in the written description and claims hereof as well as the appended drawings.
附图用来提供对本申请技术方案的进一步理解,并且构成说明书的一部分,与本申请的实施例一起用于解释本申请的技术方案,并不构成对本申请技术方案的限制。The accompanying drawings are used to provide a further understanding of the technical solution of the present application, and constitute a part of the specification, and are used together with the embodiments of the present application to explain the technical solution of the present application, and do not constitute a limitation to the technical solution of the present application.
图1是本申请一个实施例提供的用于执行数据通信方法的第一BaaS平台的架构示意图;FIG. 1 is a schematic structural diagram of a first BaaS platform for performing a data communication method provided by an embodiment of the present application;
图2是本申请一个实施例提供的“创建区块链网络”界面的示意图;Fig. 2 is a schematic diagram of the "create blockchain network" interface provided by an embodiment of the present application;
图3是本申请一个实施例提供的网络管理模块功能的示意图;Fig. 3 is a schematic diagram of the function of the network management module provided by an embodiment of the present application;
图4是本申请一个实施例提供的租户A和租户B跨平台通讯场景的示意图;FIG. 4 is a schematic diagram of a cross-platform communication scenario between tenant A and tenant B provided by an embodiment of the present application;
图5是本申请一个实施例提供的消息中心模块的结构示意图;Fig. 5 is a schematic structural diagram of a message center module provided by an embodiment of the present application;
图6是本申请一个实施例提供的第一种数据通信方法的流程图;FIG. 6 is a flowchart of a first data communication method provided by an embodiment of the present application;
图7是图6中步骤S610的一种示例方法的流程图;FIG. 7 is a flowchart of an example method of step S610 in FIG. 6;
图8是图6中步骤S620的一种示例方法的流程图;FIG. 8 is a flowchart of an exemplary method of step S620 in FIG. 6;
图9是本申请一个实施例提供的第二种数据通信方法的流程图;FIG. 9 is a flowchart of a second data communication method provided by an embodiment of the present application;
图10是图9中步骤S910的一种示例方法的流程图;FIG. 10 is a flowchart of an exemplary method of step S910 in FIG. 9;
图11是本申请一个实施例提供的主动同步的例子示意图;FIG. 11 is a schematic diagram of an example of active synchronization provided by an embodiment of the present application;
图12是图9中步骤S910的另一种示例方法的流程图;FIG. 12 is a flowchart of another exemplary method of step S910 in FIG. 9;
图13是本申请一个实施例提供的心跳同步的例子示意图;FIG. 13 is a schematic diagram of an example of heartbeat synchronization provided by an embodiment of the present application;
图14是本申请一个实施例提供的第三种数据通信方法的流程图;FIG. 14 is a flowchart of a third data communication method provided by an embodiment of the present application;
图15是本申请一个实施例提供的第四种数据通信方法的流程图;FIG. 15 is a flowchart of a fourth data communication method provided by an embodiment of the present application;
图16是图15中步骤S1310的一种示例方法的流程图;FIG. 16 is a flowchart of an example method of step S1310 in FIG. 15;
图17是图15中步骤S1310的另一种示例方法的流程图;FIG. 17 is a flowchart of another exemplary method of step S1310 in FIG. 15;
图18是本申请一个实施例提供的一种数据通信装置的结构示意图。Fig. 18 is a schematic structural diagram of a data communication device provided by an embodiment of the present application.
为了使本申请的目的、技术方案及优点更加清楚明白,以下结合附图及实施例,对本申请进行进一步详细说明。应当理解,此处所描述的具体实施例仅用以解释本申请,并不用于限定本申请。In order to make the purpose, technical solution and advantages of the present application clearer, the present application will be further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described here are only used to explain the present application, not to limit the present application.
需要说明的是,虽然在流程图中示出了逻辑顺序,但是在某些情况下,可以以不同于流程图中的顺序执行所示出或描述的步骤。说明书和权利要求书及上述附图的描述中,多个(或多项)的含义是两个以上,大于、小于、超过等理解为不包括本数,以上、以下、以内等理解为包括本数。It should be noted that although a logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than in the flowchart. In the specification, claims, and descriptions of the above drawings, multiple (or multiple) means more than two, greater than, less than, exceeding, etc. are interpreted as not including the original number, and above, below, within, etc. are understood as including the original number.
本申请提供了一种数据通信方法及其装置、存储介质、程序产品,首先部署区块链网络,接着向第二BaaS平台发送用于邀请第二BaaS平台的区块链节点进入区块链网络的邀请信息,然后接收第二BaaS平台根据邀请信息发送的反馈信息,如果反馈信息表征第二BaaS平台的区块链节点同意加入区块链网络,则将第二BaaS平台的区块链节点加入到区块链网络,最后通过第一BaaS平台创建的区块链网络,将第一BaaS平台和第二BaaS平台进行数据通信,即是说,本申请实施例的方案能够实现在不同云平台、不同区域之间协同组网,因此能够实现不同云平台之间的数据交换和资源共享,以达到跨平台通讯目的。The present application provides a data communication method and its device, storage medium, and program product. Firstly, a blockchain network is deployed, and then a blockchain node for inviting the second BaaS platform to enter the blockchain network is sent to the second BaaS platform. The invitation information of the second BaaS platform, and then receive the feedback information sent by the second BaaS platform according to the invitation information. If the feedback information indicates that the blockchain node of the second BaaS platform agrees to join the blockchain network, the blockchain node of the second BaaS platform will join Finally, through the blockchain network created by the first BaaS platform, data communication between the first BaaS platform and the second BaaS platform is carried out. Cooperative networking between different regions enables data exchange and resource sharing between different cloud platforms to achieve cross-platform communication.
下面结合附图,对本申请实施例作进一步阐述。The embodiments of the present application will be further described below in conjunction with the accompanying drawings.
如图1所示,图1是本申请一个实施例提供的用于执行数据通信方法的第一BaaS平台 100的架构示意图。在图1的示例中,该第一BaaS平台100包括区块链底层引擎模块130、区域管理模块110、网络管理模块120和消息中心模块140,其中,网络管理模块120分别与区块链底层引擎模块130、区域管理模块110、消息中心模块140通讯连接。As shown in FIG. 1, FIG. 1 is a schematic structural diagram of a first BaaS platform 100 for performing a data communication method provided by an embodiment of the present application. In the example of FIG. 1 , the first BaaS platform 100 includes a blockchain underlying engine module 130, an area management module 110, a network management module 120, and a message center module 140, wherein the network management module 120 is connected to the blockchain underlying engine module respectively. The module 130, the area management module 110, and the message center module 140 are connected by communication.
区块链底层引擎模块130可以基于联盟链实现引擎,其中,联盟链包括Hyperledger Fabric(超级账本)、Fisco Bcos(金融版区块链底层平台)等开源组件。需要说明的是,联盟链通常是由若干个机构共同参与管理的区块链,每个机构都运行着一个或多个节点,其中的数据只允许系统内不同的机构进行读写和发送交易,并且共同来记录交易数据。参与到区块链系统中的每个节点都是经过许可的,未经许可的节点是不可以接入到系统中。除此之外,联盟链采用授权联盟链方式运行,其中主要包含三大主体:第一类为创始委员会,第二类为参与出块的联盟节点群组,第三类为联盟链见证者。The blockchain underlying engine module 130 can implement the engine based on the consortium chain, wherein the consortium chain includes open source components such as Hyperledger Fabric (super ledger), Fisco Bcos (financial version of the blockchain underlying platform). It should be noted that the consortium chain is usually a block chain jointly managed by several institutions, each of which runs one or more nodes, and the data in it only allows different institutions in the system to read, write and send transactions. And work together to record transaction data. Every node participating in the blockchain system is licensed, and unlicensed nodes cannot be connected to the system. In addition, the consortium chain operates in an authorized consortium chain mode, which mainly includes three main bodies: the first category is the founding committee, the second category is the consortium node group participating in block generation, and the third category is the consortium chain witnesses.
区域管理模块110主要负责注册、搜集不同区域的信息,以供后续的组网使用,其中,不同区域的信息包括参数名称、数据类型以及需要备注的信息等,参数名称包括域名、地址以及判断是否是本地域等,数据类型包括整型、浮点型、字符串和布尔类型等,在此不做具体限制。例如,域配置如下表1所示,该表包括参数名称、数据类型、可选项以及备注项,其中,可选项中的内容表示是否设置对应的参数。根据下面表1可以看出,该区域的域名的数据类型是字符串,不对该参数进行设置;该区域的IP地址的数据类型是字符串,且不对该参数进行设置;该区域为本地域,且对该参数进行设置。在一实施例中,假设配置的区域是本地域,则区域管理模块110可以自动发现本平台的区域信息。The area management module 110 is mainly responsible for registering and collecting information in different areas for use in subsequent networking. The information in different areas includes parameter names, data types, and information that needs to be noted, and the parameter names include domain names, addresses, and judging whether It is a local domain, etc., and the data types include integer, floating point, string, Boolean, etc., and there is no specific limitation here. For example, the domain configuration is shown in Table 1 below, which includes parameter names, data types, optional items, and remark items, where the content in the optional items indicates whether to set the corresponding parameters. According to Table 1 below, it can be seen that the data type of the domain name in this area is a string, and this parameter is not set; the data type of the IP address in this area is a string, and this parameter is not set; this area is a local domain, And set this parameter. In one embodiment, assuming that the configured area is a local domain, the area management module 110 can automatically discover the area information of the platform.
表1Table 1
参数名称parameter name | 数据类型type of data | 可选optional | 备注Remark |
域名domain name | 字符串string | 否no | 名称name |
地址address | 字符串string | 否no | IPIP |
是否为本地域Is it a local domain | 布尔Boolean | 是yes | TrueTrue |
网络管理模块120的功能可以包括网络部署、节点管理和邀请加入网络等,在此不做具体限定。除此之外,还可以通过“创建区块链网络”界面,使得用户简单、方便地一键式部署区块链网络。例如,假设“创建区块链网络”界面如图2所示,“创建区块链网络”界面包括“区块链网络名称”项目、“区块链网络描述”项目、“区块链网络类型”项目、“共识策略”项目、“安全机制”项目、“选择域”项目、“网络引擎”项目、“引擎版本”项目、“状态数据库”项目、“块存储”项目、“CA(Certificate Authority,电子认证)服务”项目和“peer(平级)节点组织”等内容,当部署区块链网络时,可以通过该界面设置区块链网络的相关参数,例如在“区块链网络名称”项目中设置网络名称(如XX网络),在“区块链网络描述”项目中对设置的区块链网络填写相关介绍信息,在“区块链网络类型”项目可以设置区块链网络类型(如联盟链、私有链等),在“共识策略”项目中设置相关策略,在“安全机制”项目中选择相关机制(如ECDSA(Elliptic Curve Digital Signature Algorithm,椭圆曲线数字签名算法)或者国密安全算法),在“选择域”项目中填写相关IP地址(如X.X.X.X IP地址),在“网络引擎”项目中选择设置相关引擎(如XXX引擎),在“引擎版本”项目中选择相关版本(如V2_2_1),在“状态数据库”项目中选择相关数据库(如A数据库、B数据库或者C数据库),在“块存储”项目中选择相关块存储(如文件数据库或者关系数据库),在“CA(Certificate Authority,电子认证)服务”项目中选择是否有CA服务,以及在“peer(平级)节点组织”中选择节点组织名称、peer节点数量和输入组织描述等。The functions of the network management module 120 may include network deployment, node management, invitation to join the network, etc., which are not specifically limited here. In addition, users can easily and conveniently deploy a blockchain network with one click through the "Create Blockchain Network" interface. For example, assuming that the "Create Blockchain Network" interface is shown in Figure 2, the "Create Blockchain Network" interface includes the "Blockchain Network Name" item, the "Blockchain Network Description" item, the "Blockchain Network Type " project, "consensus strategy" project, "security mechanism" project, "choice domain" project, "network engine" project, "engine version" project, "state database" project, "block storage" project, "CA (Certificate Authority , electronic certification) service" project and "peer (level) node organization", when deploying the blockchain network, you can set the relevant parameters of the blockchain network through this interface, for example, in the "blockchain network name" Set the network name (such as XX network) in the project, fill in the relevant introduction information for the set blockchain network in the "Blockchain Network Description" item, and set the blockchain network type in the "Blockchain Network Type" item ( Such as alliance chain, private chain, etc.), set relevant policies in the "Consensus Strategy" item, and select the relevant mechanism in the "Security Mechanism" item (such as ECDSA (Elliptic Curve Digital Signature Algorithm, Elliptic Curve Digital Signature Algorithm) or National Secret Security Algorithm), fill in the relevant IP address (such as X.X.X.X IP address) in the "Select Domain" item, select and set the relevant engine (such as XXX engine) in the "Network Engine" item, and select the relevant version in the "Engine Version" item (such as V2_2_1), select the relevant database (such as A database, B database or C database) in the "status database" item, select the relevant block storage (such as file database or relational database) in the "block storage" item, and select "CA (Certificate In the "Authority, electronic certification) service" item, select whether there is a CA service, and in the "peer (level) node organization", select the node organization name, the number of peer nodes, and enter the organization description, etc.
在一实施例中,参照图3,网络管理模块120可以在区块链底层引擎模块130中选择区块链底层引擎创建区块链网络,比如网络A,创建网络时,可以通过区域管理模块110配置的区域信息,将不同区域的平台节点组网,比如第一BaaS平台100和第二BaaS平台,接入此网络中;同时网络管理模块120还能在已创建的网络里邀请其他平台的租户加入区块链网络,比如租户A和租户B。租户之间能够通过区块链网络进行交互,从而屏蔽了区块链底层引擎相互通信的复杂问题,简化了用户操作。举一示例,如图4所示,租户A和租户B分别在本地部署一套BaaS平台,租户A和租户B通过区域管理模块,进行区域注册,租户A选择区块链底层引擎,在本地的BaaS平台上部署区块链网络,接着租户A发送消息给其他域的租户B,邀请加盟网络,此时会通过租户A本地消息中心模块进行跨平台的邀请消息发送,租户B在本地的消息中心模块接收到租户A发过来的邀请通知,选择同意加入区块链网络后,更新网络配置,在区块链网络中加入组织和组织下所有节点,并同步网络信息给其他域;或者是,租户B申请加入租户A的区块链网络,从本地的消息中心模块发出申请通知,租户A审批通过后,通知租户B加入区块链网络,租户B接到通知后,更新网络配置,在区块链网络中加入组织和组织下所有节点,这使得不同租户之间在跨平台的情况下实现对同一个区块链网络的数据和资源共享交换。In one embodiment, referring to FIG. 3 , the network management module 120 can select the underlying engine of the blockchain in the underlying engine module 130 of the blockchain to create a blockchain network, such as network A. When creating a network, the regional management module 110 can Configured regional information, network platform nodes in different regions, such as the first BaaS platform 100 and the second BaaS platform, access this network; at the same time, the network management module 120 can also invite tenants of other platforms in the created network Join the blockchain network, say Tenant A and Tenant B. Tenants can interact through the blockchain network, thus shielding the complex issues of mutual communication between the underlying engines of the blockchain and simplifying user operations. As an example, as shown in Figure 4, tenant A and tenant B respectively deploy a set of BaaS platforms locally. Tenant A and tenant B perform regional registration through the regional management module. Tenant A selects the underlying engine of the blockchain. The blockchain network is deployed on the BaaS platform, and then tenant A sends a message to tenant B in other domains to invite to join the network. At this time, the cross-platform invitation message will be sent through tenant A's local message center module, and tenant B will be in the local message center. The module receives the invitation notification sent by tenant A, chooses to agree to join the blockchain network, updates the network configuration, joins the organization and all nodes under the organization in the blockchain network, and synchronizes network information to other domains; or, the tenant B applies to join the blockchain network of tenant A, and sends an application notification from the local message center module. After the approval of tenant A, tenant B is notified to join the blockchain network. After receiving the notification, tenant B updates the network configuration. The organization and all nodes under the organization are added to the blockchain network, which enables different tenants to share and exchange data and resources on the same blockchain network under cross-platform conditions.
如图5所示,消息中心模块140包括接口层141、推送池144、心跳池142和通讯层143等,该模块的功能包括跨平台的消息同步等,在此不作具体限定。其中,消息同步主要采用主从同步的方式,对于每个网络,网络发起的BaaS平台为主BaaS平台,加入网络的BaaS平台为从BaaS平台,网络配置变动则由主BaaS平台向从BaaS平台同步,除此之外,从BaaS平台也可以向主BaaS平台获取所有网络配置数据。As shown in FIG. 5 , the message center module 140 includes an interface layer 141 , a push pool 144 , a heartbeat pool 142 , and a communication layer 143 . The functions of this module include cross-platform message synchronization, etc., which are not specifically limited here. Among them, message synchronization mainly adopts the master-slave synchronization method. For each network, the BaaS platform initiated by the network is the master BaaS platform, and the BaaS platform that joins the network is the slave BaaS platform. Network configuration changes are synchronized from the master BaaS platform to the slave BaaS platform. , in addition, all network configuration data can also be obtained from the main BaaS platform from the BaaS platform.
在一实施例中,主BaaS平台中的网络管理模块向主BaaS平台中的消息中心模块140发布消息,该消息中心模块140的接口层141接收消息,通过该接口层141接收的消息,会放入该消息中心模块140的推送池144(或者心跳池142)的推送队列,接着推送池144(或者心跳池142)根据规则将推送队列中的消息打包,发送至该网络管理模块的通讯层143,该通讯层143根据目的地址,向目的地址发送消息,目的地址通过从BaaS平台中的通讯层143接收消息,且向从BaaS平台中的推送池144(或者心跳池142)的接收队列发送消息,接着从BaaS平台中的推送池144(或者心跳池142)又向从BaaS平台中的接口层141发送消息,然后从BaaS平台中的接口层141向从BaaS平台中的网络管理模块,以使从BaaS平台中的网络管理模块进行消息请求分发处理。同样地,从BaaS平台也可以向主BaaS平台发送获取所有网络配置数据的消息,消息发送过程与该从BaaS平台接收消息的过程相反,在此不再赘述。In one embodiment, the network management module in the main BaaS platform issues a message to the message center module 140 in the main BaaS platform, and the interface layer 141 of the message center module 140 receives the message, and the message received through the interface layer 141 will be released. Enter the push queue of the push pool 144 (or heartbeat pool 142) of the message center module 140, then the push pool 144 (or heartbeat pool 142) packs the message in the push queue according to the rules, and sends it to the communication layer 143 of the network management module , the communication layer 143 sends a message to the destination address according to the destination address, and the destination address receives the message from the communication layer 143 in the BaaS platform, and sends a message to the receiving queue of the push pool 144 (or heartbeat pool 142) in the BaaS platform , then send a message from the push pool 144 (or heartbeat pool 142) in the BaaS platform to the interface layer 141 in the BaaS platform, then from the interface layer 141 in the BaaS platform to the network management module in the BaaS platform, so that Message request distribution processing is performed from the network management module in the BaaS platform. Similarly, the slave BaaS platform can also send a message to obtain all network configuration data to the master BaaS platform. The message sending process is opposite to the process of receiving messages from the slave BaaS platform, and will not be repeated here.
需要说明的是,第二BaaS平台的架构与第一BaaS平台的架构可以是相同的,第二BaaS平台也可以包括区块链底层引擎模块、区域管理模块、网络管理模块和消息中心模块140等,根据实际情况而定,在此不做具体限制。It should be noted that the architecture of the second BaaS platform may be the same as that of the first BaaS platform, and the second BaaS platform may also include a block chain underlying engine module, a regional management module, a network management module, and a message center module 140, etc. , depends on the actual situation, and no specific limitation is made here.
本申请实施例描述的第一BaaS平台以及应用场景是为了更加清楚的说明本申请实施例的技术方案,并不构成对于本申请实施例提供的技术方案的限定,本领域技术人员可知,随 着第一BaaS平台的架构的演变和新应用场景的出现,本申请实施例提供的技术方案对于类似的技术问题,同样适用。The first BaaS platform and application scenarios described in the embodiments of the present application are to more clearly illustrate the technical solutions of the embodiments of the present application, and do not constitute limitations on the technical solutions provided in the embodiments of the present application. Those skilled in the art know that as The evolution of the architecture of the first BaaS platform and the emergence of new application scenarios, the technical solutions provided by the embodiments of the present application are also applicable to similar technical problems.
本领域技术人员可以理解的是,图1中示出的第一BaaS平台、图5中示出的消息中心模块的结构并不构成对本申请实施例的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。Those skilled in the art can understand that the structure of the first BaaS platform shown in Figure 1 and the message center module shown in Figure 5 does not constitute a limitation to the embodiment of the application, and may include more or more Fewer components, or combinations of certain components, or different arrangements of components.
基于上述第一BaaS平台,下面提出本申请的数据通信方法的各个实施例。Based on the above-mentioned first BaaS platform, various embodiments of the data communication method of the present application are proposed below.
如图6所示,图6是本申请一个实施例提供的数据通信方法的流程图,该数据通信方法可以应用于第一BaaS平台,例如图1所示第一BaaS平台。该数据通信方法可以包括但不限于有步骤S610、步骤S620、步骤S630、步骤S640和步骤S650。As shown in FIG. 6 , FIG. 6 is a flowchart of a data communication method provided by an embodiment of the present application. The data communication method can be applied to a first BaaS platform, such as the first BaaS platform shown in FIG. 1 . The data communication method may include but not limited to step S610, step S620, step S630, step S640 and step S650.
步骤S610:部署区块链网络。Step S610: Deploy the blockchain network.
本步骤中,部署区块链网络,以便于后续步骤通过该区块链网络与与第二BaaS平台进行数据通信。In this step, a blockchain network is deployed, so that data communication with the second BaaS platform can be performed through the blockchain network in subsequent steps.
步骤S620:向第二BaaS平台发送邀请信息,邀请信息用于邀请第二BaaS平台的区块链节点进入区块链网络。Step S620: Send invitation information to the second BaaS platform, where the invitation information is used to invite the blockchain nodes of the second BaaS platform to enter the blockchain network.
本步骤中,通过步骤S610部署区块链网络,因此,第一BaaS平台可以向第二BaaS平台发送用于邀请第二BaaS平台的区块链节点进入区块链网络的邀请信息,以便于第二BaaS平台根据该邀请信息向第一BaaS平台发送反馈信息。In this step, the blockchain network is deployed through step S610, therefore, the first BaaS platform can send invitation information for inviting the blockchain nodes of the second BaaS platform to enter the blockchain network to the second BaaS platform, so that the second BaaS platform The second BaaS platform sends feedback information to the first BaaS platform according to the invitation information.
步骤S630:接收第二BaaS平台根据邀请信息发送的反馈信息。Step S630: Receive the feedback information sent by the second BaaS platform according to the invitation information.
本步骤中,由于在步骤S620中向第二BaaS平台已经发送了邀请信息,因此,可以接收第二BaaS平台根据该邀请信息发送的反馈信息,以便于后续步骤S640对该反馈信息验证,当反馈信息表征第二BaaS平台的区块链节点同意加入区块链网络,将第二BaaS平台的区块链节点加入到区块链网络。In this step, since the invitation information has been sent to the second BaaS platform in step S620, the feedback information sent by the second BaaS platform according to the invitation information can be received, so that the subsequent step S640 can verify the feedback information. The information indicates that the blockchain nodes of the second BaaS platform agree to join the blockchain network, and the blockchain nodes of the second BaaS platform are added to the blockchain network.
需要说明的是,该反馈信息可以是用于表达第二BaaS平台同意加入区块链网络的意思,也可以是用于表达第二BaaS平台拒绝加入区块链网络的意思,在此不做具体限定。It should be noted that the feedback information can be used to express the meaning that the second BaaS platform agrees to join the blockchain network, or it can be used to express the meaning that the second BaaS platform refuses to join the blockchain network. limited.
步骤S640:当反馈信息表征第二BaaS平台的区块链节点同意加入区块链网络,将第二BaaS平台的区块链节点加入到区块链网络。Step S640: When the feedback information indicates that the blockchain node of the second BaaS platform agrees to join the blockchain network, join the blockchain node of the second BaaS platform to the blockchain network.
本步骤中,由于在步骤S630中接收到了反馈信息,因此,可以对该反馈信息进行验证,当反馈信息表征第二BaaS平台的区块链节点同意加入区块链网络,则将第二BaaS平台的区块链节点加入到区块链网络,以便于后续步骤通过该区块链网络将第一BaaS平台与第二BaaS平台进行数据通信。In this step, since the feedback information is received in step S630, the feedback information can be verified. When the feedback information indicates that the blockchain node of the second BaaS platform agrees to join the blockchain network, the second BaaS platform will The blockchain node of the blockchain is added to the blockchain network, so that the subsequent steps can communicate data between the first BaaS platform and the second BaaS platform through the blockchain network.
步骤S650:通过区块链网络与第二BaaS平台进行数据通信。Step S650: Perform data communication with the second BaaS platform through the blockchain network.
本步骤中,由于在步骤S640中已经将第二BaaS平台加入到区块链网络中,因此,通过第一BaaS平台创建的区块链网络,可以将第一BaaS平台和第二BaaS平台进行数据通信。In this step, since the second BaaS platform has been added to the blockchain network in step S640, the first BaaS platform and the second BaaS platform can be connected to each other through the blockchain network created by the first BaaS platform. communication.
本实施例中,通过采用上述步骤S610至步骤S650,在第一BaaS平台上部署区块链网络之后,首先向第二BaaS平台发送用于邀请第二BaaS平台的区块链节点进入区块链网络的邀请信息,之后接收第二BaaS平台根据邀请信息发送的反馈信息,接着对该反馈信息进行验证,当反馈信息表征第二BaaS平台的区块链节点同意加入区块链网络,则将第二BaaS平台的区块链节点加入到区块链网络,最后第一BaaS平台通过区块链网络与第二BaaS平台进行数据 通信,即是说,本申请实施例的方案能够实现在不同云平台、不同区域之间协同组网,因此,本申请实施例的方案能够实现不同云平台之间的数据交换和资源共享,以达到跨平台通讯目的。In this embodiment, by adopting the above steps S610 to S650, after deploying the blockchain network on the first BaaS platform, first send to the second BaaS platform to invite the blockchain node of the second BaaS platform to enter the blockchain The invitation information of the network, and then receive the feedback information sent by the second BaaS platform according to the invitation information, and then verify the feedback information. When the feedback information indicates that the blockchain node of the second BaaS platform agrees to join the blockchain network, the first The blockchain nodes of the second BaaS platform are added to the blockchain network, and finally the first BaaS platform communicates with the second BaaS platform through the blockchain network. 1. Collaborative networking between different regions. Therefore, the solution of the embodiment of the present application can realize data exchange and resource sharing between different cloud platforms, so as to achieve the purpose of cross-platform communication.
在一实施例中,如图7所示,对步骤S610进一步的说明,该步骤S610可以包括但不限于有步骤S710、步骤S720和步骤S730。In an embodiment, as shown in FIG. 7 , step S610 is further described, and step S610 may include but not limited to step S710 , step S720 and step S730 .
步骤S710:选择目标区块链引擎和区域。Step S710: Select the target blockchain engine and region.
本步骤中,由于通过在区块链底层引擎模块中选择目标区块链引擎和区域,因此,后续步骤可以对该区域进行配置处理。In this step, since the target blockchain engine and region are selected in the underlying blockchain engine module, the region can be configured in subsequent steps.
需要说明的是,目标区块链引擎可以是区块链底层引擎,也可以是其他引擎,在此不做具体限制。该目标区块链引擎可以是基于联盟链实现的,比如,目标区块链引擎可以由Hyperledger Fabric、Fisco Bcos等开源组件实现。It should be noted that the target blockchain engine can be the underlying engine of the blockchain, or other engines, and no specific limitation is set here. The target blockchain engine can be implemented based on the consortium chain. For example, the target blockchain engine can be implemented by open source components such as Hyperledger Fabric and Fisco Bcos.
步骤S720:对区域进行配置处理,得到区域信息。Step S720: Perform configuration processing on the area to obtain area information.
本步骤中,由于在步骤S710中选择了区域,因此,可以对该区域进行配置处理,得到区域信息,以便获取第二BaaS平台的目的地址。In this step, since the area is selected in step S710, the area can be configured to obtain area information, so as to obtain the destination address of the second BaaS platform.
步骤S730:根据目标区块链引擎和区域信息部署区块链网络。Step S730: Deploy the blockchain network according to the target blockchain engine and regional information.
本步骤中,由于在步骤S710中得到了目标区块链引擎和在步骤S720中配置了区域信息,因此,可以根据该目标区块链引擎和区域信息部署区块链网络。In this step, since the target blockchain engine is obtained in step S710 and the region information is configured in step S720, the blockchain network can be deployed according to the target blockchain engine and region information.
本实施例中,通过采用上述步骤S710至步骤S730,网络管理模块通过在区块链底层引擎模块中选择目标区块链引擎和区域,接着对该区域进行配置处理,得到区域信息,最后该网络管理模块根据该目标区块链引擎和区域信息部署区块链网络,以便于不同云平台之间通过区块链网络进行交互,从而屏蔽了区块链底层引擎相互通信的复杂问题,简化了用户操作。In this embodiment, by adopting the above steps S710 to S730, the network management module selects the target blockchain engine and region in the blockchain underlying engine module, and then configures the region to obtain region information, and finally the network The management module deploys the blockchain network according to the target blockchain engine and regional information, so that different cloud platforms can interact through the blockchain network, thus shielding the complex issues of mutual communication between the underlying blockchain engines and simplifying the user experience. operate.
在一实施例中,如图8所示,对步骤S620进一步的说明,该步骤S620可以包括但不限于有步骤S810、步骤S820和步骤S830。In an embodiment, as shown in FIG. 8 , step S620 is further described, and step S620 may include but not limited to step S810 , step S820 and step S830 .
步骤S810:根据区块链网络的网络信息生成邀请信息。Step S810: Generate invitation information according to the network information of the blockchain network.
本步骤中,网络管理模块根据区块链网络的网络信息生成邀请信息,以便于后续步骤可以对该邀请信息进行封装处理得到封装后的邀请信息。In this step, the network management module generates invitation information according to the network information of the blockchain network, so that the invitation information can be encapsulated in subsequent steps to obtain the encapsulated invitation information.
可以理解的是,邀请信息可以用来表达对其他BaaS平台加入到该区块链网络的愿望。还需要说明的是,在生成邀请信息的当前时刻,这些BaaS平台与第一BaaS平台是不属于同一个网络的。It is understandable that the invitation message can be used to express the desire for other BaaS platforms to join the blockchain network. It should also be noted that at the moment when the invitation information is generated, these BaaS platforms and the first BaaS platform do not belong to the same network.
还需要说明的是,该邀请信息可以是一个,也可以是多个,根据实际情况而定,在此不做具体限定。It should also be noted that the invitation information may be one or more, depending on the actual situation, which is not specifically limited here.
步骤S820:对邀请信息进行封装处理得到封装后的邀请信息。Step S820: Encapsulate the invitation information to obtain encapsulated invitation information.
本步骤中,由于在步骤S810中生成了邀请信息,因此,消息中心模块可以对邀请信息进行封装处理,得到封装后的邀请信息,以便于后续步骤向第二BaaS平台发送封装后的邀请信息。该步骤可以使得邀请信息可靠且准确地发送到目的地。In this step, since the invitation information is generated in step S810, the message center module can encapsulate the invitation information to obtain the encapsulated invitation information, so as to send the encapsulated invitation information to the second BaaS platform in subsequent steps. This step can make the invitation information sent to the destination reliably and accurately.
需要说明的是,可以根据封装协议对邀请信息进行封装。比如,把该邀请信息映射到封装协议的净荷中,然后填充对应协议的包头,形成封装协议的数据包,并完成速率适配。还需要说明的是,封装处理可以是在所发送的数据包上附加上目标地址,本地地址,以及一些 用于纠错的字节,除此之外,还可以进行加密处理等等,这使得邀请信息在传输过程中安全性和可靠性更高。It should be noted that the invitation information may be encapsulated according to an encapsulation protocol. For example, the invitation information is mapped to the payload of the encapsulation protocol, and then the header of the corresponding protocol is filled to form a data packet of the encapsulation protocol, and the rate adaptation is completed. It should also be noted that the encapsulation process can be to add the destination address, local address, and some bytes for error correction to the sent data packet. In addition, it can also perform encryption processing, etc., which makes Invitation information is more secure and reliable during transmission.
还需要说明的是,封装协议是第一BaaS平台与所要发送的平台共同遵循和协商好的规则。It should also be noted that the encapsulation protocol is a rule that the first BaaS platform and the platform to be sent jointly follow and negotiate.
步骤S830:向第二BaaS平台发送封装后的邀请信息。Step S830: Send the encapsulated invitation information to the second BaaS platform.
本步骤中,由于在步骤S820中得到了封装后的邀请信息,因此,消息中心模块可以向第二BaaS平台发送封装后的邀请信息,以便后续步骤可以接收到第二BaaS平台根据该邀请信息发送的反馈信息。In this step, since the encapsulated invitation information is obtained in step S820, the message center module can send the encapsulated invitation information to the second BaaS platform, so that the subsequent steps can receive the invitation information sent by the second BaaS platform according to the invitation information. feedback information.
本实施例中,通过采用上述步骤S810至步骤S830,网络管理模块可以根据区块链网络的网络信息生成邀请信息,接着消息中心模块可以对邀请信息进行封装处理,得到封装后的邀请信息,最后向第二BaaS平台发送封装后的邀请信息,从而为后续第一BaaS平台与第二BaaS平台之间的数据通信做准备。In this embodiment, by adopting the above steps S810 to S830, the network management module can generate invitation information according to the network information of the blockchain network, and then the message center module can encapsulate the invitation information to obtain the encapsulated invitation information, and finally The encapsulated invitation information is sent to the second BaaS platform, so as to prepare for subsequent data communication between the first BaaS platform and the second BaaS platform.
在一实施例中,假设第一BaaS平台想要邀请第二BaaS平台的区块链节点加入区块链网络,则第一BaaS平台的消息中心模块将会根据区块链网络的网络信息生成邀请信息,然后该消息中心模块的接口层将该邀请信息发送到消息中心模块的推送池的推送队列中,根据规则对该邀请信息进行封装,接着将封装后的邀请信息发送给消息中心模块的通讯层,通过调用协议,比如grpc(google Remote Procedure Calls,谷歌远程过程调用)协议、xml-rpc(XML Remote Procedure Call,XML远程过程调用)协议或者binary-rpc(binary Remote Procedure Call,二进制远程过程调用)协议,根据第二BaaS平台的目的地址发送给第二BaaS平台的通讯层,接着第二BaaS平台的通讯层又将封装后的邀请信息发送给第二BaaS平台的推送池的接收队列,接收队列请求发送给第二BaaS平台的接口层,以使第二BaaS平台的接口层发送给第二BaaS平台的的网络管理模块进行消息请求处理。In one embodiment, assuming that the first BaaS platform wants to invite the blockchain node of the second BaaS platform to join the blockchain network, the message center module of the first BaaS platform will generate an invitation according to the network information of the blockchain network information, and then the interface layer of the message center module sends the invitation information to the push queue of the push pool of the message center module, encapsulates the invitation information according to the rules, and then sends the encapsulated invitation information to the communication of the message center module Layer, through calling protocols, such as grpc (google Remote Procedure Calls, Google Remote Procedure Call) protocol, xml-rpc (XML Remote Procedure Call, XML Remote Procedure Call) protocol or binary-rpc (binary Remote Procedure Call, binary remote procedure call ) protocol, according to the destination address of the second BaaS platform, it is sent to the communication layer of the second BaaS platform, and then the communication layer of the second BaaS platform sends the encapsulated invitation information to the receiving queue of the push pool of the second BaaS platform, and receives The queue request is sent to the interface layer of the second BaaS platform, so that the interface layer of the second BaaS platform sends it to the network management module of the second BaaS platform to process the message request.
在一实施例中,如图9所示,数据通信方法还可以包括但不限于有步骤S910。In an embodiment, as shown in FIG. 9 , the data communication method may further include but not limited to step S910.
步骤S910:根据区块链网络的网络信息对第二BaaS平台进行信息同步更新处理。Step S910: Perform information synchronization update processing on the second BaaS platform according to the network information of the blockchain network.
本实施例中,由于在上述步骤中第一BaaS平台已经通过区块链网络与第二BaaS平台进行数据通信,因此,可以根据区块链网络的网络信息对第二第二BaaS平台进行信息同步更新处理,这保障了同一区块链网络中的不同云平台之间通信的一致性和可靠性,减少通信故障和传输错误。In this embodiment, since the first BaaS platform has performed data communication with the second BaaS platform through the blockchain network in the above steps, information synchronization can be performed on the second and second BaaS platforms according to the network information of the blockchain network Update processing, which ensures the consistency and reliability of communication between different cloud platforms in the same blockchain network, reducing communication failures and transmission errors.
需要说明的是,同步更新的方式可以包括主动同步和心跳同步等,在此不做具体限制。It should be noted that, the ways of synchronizing and updating may include active synchronization and heartbeat synchronization, etc., which are not specifically limited here.
在一实施例中,如图10所示,对步骤S910进一步的说明,该步骤S910可以包括但不限于有步骤S1010、步骤S1020和步骤S1030。In an embodiment, as shown in FIG. 10 , step S910 is further described, and step S910 may include but not limited to step S1010 , step S1020 and step S1030 .
步骤S1010:根据区块链网络的网络信息得到第一配置更新信息。Step S1010: Obtain the first configuration update information according to the network information of the blockchain network.
本步骤中,由于在步骤S730中已经部署了区块链网络,因此可以根据区块链网络的网络信息得到第一配置更新信息,以便于后续步骤对该第一配置更新信息进行打包处理。In this step, since the blockchain network has been deployed in step S730, the first configuration update information can be obtained according to the network information of the blockchain network, so as to package the first configuration update information in subsequent steps.
需要说明的是,第一配置更新信息是第一BaaS平台的配置信息。It should be noted that the first configuration update information is configuration information of the first BaaS platform.
还需要说明的是,第一配置更新信息可以包括域名、ip地址等内容,在此不做具体限定。It should also be noted that the first configuration update information may include content such as domain name and IP address, which is not specifically limited here.
步骤S1020:对第一配置更新信息进行打包处理,得到第一同步信息。Step S1020: Perform packaging processing on the first configuration update information to obtain first synchronization information.
本步骤中,由于在步骤S1010中得到了第一配置更新信息,因此,可以对第一配置更新信息进行打包处理,得到第一同步消息,以便于后续步骤可以向第二BaaS平台发送第一同步 信息,使得第二BaaS平台根据第一同步信息进行信息同步更新处理。In this step, since the first configuration update information is obtained in step S1010, the first configuration update information can be packaged to obtain the first synchronization message, so that the subsequent steps can send the first synchronization message to the second BaaS platform Information, so that the second BaaS platform performs information synchronization update processing according to the first synchronization information.
需要说明的是,可以对第一配置更新信息进行定期打包,可以根据实际情况决定,在此不作具体限定。It should be noted that the first configuration update information may be packaged periodically, which may be determined according to actual conditions, and is not specifically limited here.
步骤S1030:向第二BaaS平台发送第一同步信息,使得第二BaaS平台根据第一同步信息进行信息同步更新处理。Step S1030: Send the first synchronization information to the second BaaS platform, so that the second BaaS platform performs information synchronization update processing according to the first synchronization information.
本步骤中,由于在步骤S1020中得到了第一同步信息,因此,可以向第二BaaS平台发送第一同步信息,使得第二BaaS平台根据第一同步信息进行信息同步更新处理,这保障了同一区块链网络中的不同云平台之间通信的一致性和可靠性,减少通信故障和传输错误。In this step, since the first synchronization information is obtained in step S1020, the first synchronization information can be sent to the second BaaS platform, so that the second BaaS platform performs information synchronization update processing according to the first synchronization information, which ensures the same Consistency and reliability of communication between different cloud platforms in the blockchain network, reducing communication failures and transmission errors.
本实施例中,通过采用上述步骤S1010至步骤S1030,根据区块链网络的网络信息得到第一配置更新信息,接着又对第一配置更新信息进行打包处理,得到第一同步信息,最后向第二BaaS平台发送第一同步信息,使得第二BaaS平台根据第一同步信息进行信息同步更新处理,从而保障了同一区块链网络中的不同云平台之间通信的一致性和可靠性,减少通信故障和传输错误。In this embodiment, by using the above steps S1010 to S1030, the first configuration update information is obtained according to the network information of the blockchain network, and then the first configuration update information is packaged to obtain the first synchronization information, and finally sent to the second The second BaaS platform sends the first synchronization information, so that the second BaaS platform performs information synchronization update processing according to the first synchronization information, thereby ensuring the consistency and reliability of communication between different cloud platforms in the same blockchain network and reducing communication glitches and transmission errors.
在一实施例中,如图11所示,假设第一BaaS平台的消息中心模块为第一消息中心模块,第二BaaS平台的消息中心模块为第二消息中心模块,第一消息中心模块包括第一配置同步模块和第一推送池,第二消息中心模块包括第二配置同步模块和第二推送池,第一配置同步模块根据区块链网络的网络信息得到第一配置更新信息,并发送给第一推送池,第一推送池对该第一配置更新信息进行定期打包,得到第一同步信息,然后第一推送池通过推送消息(或者主grpc接口)对该第一同步信息加入推送同步列表中,接着将该推送同步列表发送给第二推送池,第二推送池向第二配置同步模块通知更新同步,第二配置同步模块对第二BaaS平台进行同步更新。In one embodiment, as shown in FIG. 11 , it is assumed that the message center module of the first BaaS platform is the first message center module, the message center module of the second BaaS platform is the second message center module, and the first message center module includes the first message center module A configuration synchronization module and the first push pool, the second message center module includes the second configuration synchronization module and the second push pool, the first configuration synchronization module obtains the first configuration update information according to the network information of the block chain network, and sends it to The first push pool, the first push pool regularly packages the first configuration update information to obtain the first synchronization information, and then the first push pool adds the first synchronization information to the push synchronization list through the push message (or the main grpc interface) , then the push synchronization list is sent to the second push pool, and the second push pool notifies the second configuration synchronization module of update synchronization, and the second configuration synchronization module performs synchronization update on the second BaaS platform.
需要说明的是,第二BaaS平台可以启动监听事件,通过广播发送的方式获取第一配置更新信息,进行同步更新。除此之外,第二BaaS平台也可以采用其他方式获取第一配置更新信息,比如单播、组播等等,在此不做具体限制。It should be noted that the second BaaS platform can start monitoring events, obtain the first configuration update information through broadcasting, and perform synchronous updates. In addition, the second BaaS platform may also obtain the first configuration update information in other ways, such as unicast, multicast, etc., which are not specifically limited here.
在另一实施例中,如图12所示,对步骤S910进一步的说明,该步骤S910可以包括但不限于有步骤S1110、步骤S1120和步骤S1130。In another embodiment, as shown in FIG. 12 , step S910 is further described, and step S910 may include but not limited to step S1110 , step S1120 and step S1130 .
步骤S1110:接收第二BaaS平台的第一心跳同步消息,第一心跳同步消息包括第二BaaS平台的当前配置信息。Step S1110: Receive a first heartbeat synchronization message of the second BaaS platform, where the first heartbeat synchronization message includes current configuration information of the second BaaS platform.
本步骤中,消息中心模块接收第二BaaS平台的包括第二BaaS平台的当前配置信息的第一心跳同步消息,以便于后续步骤根据区块链网络的网络信息对第二BaaS平台的当前配置信息进行对比处理。In this step, the message center module receives the first heartbeat synchronization message of the second BaaS platform including the current configuration information of the second BaaS platform, so that subsequent steps can update the current configuration information of the second BaaS platform according to the network information of the blockchain network for comparison.
需要说明的是,第二BaaS平台的当前配置信息可以包括网络、通道、组织、节点或者是链码的配置列表,配置列表可以包括ID和哈希值等,在此不作具体限定。It should be noted that the current configuration information of the second BaaS platform may include a configuration list of networks, channels, organizations, nodes, or chaincodes, and the configuration list may include IDs and hash values, which are not specifically limited here.
步骤S1120:根据区块链网络的网络信息对第二BaaS平台的当前配置信息进行对比处理,得到第二同步信息。Step S1120: Compare and process the current configuration information of the second BaaS platform according to the network information of the blockchain network to obtain second synchronization information.
本步骤中,由于在步骤S1110中得到了包括第二BaaS平台的当前配置信息的第一心跳同步消息,因此,可以根据区块链网络的网络信息对第二BaaS平台的当前配置信息进行对比处理,得到第二同步信息,以便于后续步骤向第二BaaS平台发送第二同步信息,使得第二BaaS 平台根据第二同步信息进行信息同步更新处理。In this step, since the first heartbeat synchronization message including the current configuration information of the second BaaS platform is obtained in step S1110, the current configuration information of the second BaaS platform can be compared according to the network information of the blockchain network , to obtain the second synchronization information, so as to send the second synchronization information to the second BaaS platform in a subsequent step, so that the second BaaS platform performs information synchronization update processing according to the second synchronization information.
步骤S1130:向第二BaaS平台发送第二同步信息,使得第二BaaS平台根据第二同步信息进行信息同步更新处理。Step S1130: Send the second synchronization information to the second BaaS platform, so that the second BaaS platform performs information synchronization update processing according to the second synchronization information.
本步骤中,由于在步骤S1120中得到了第二同步信息,因此,可以向第二BaaS平台发送第二同步信息,使得第二BaaS平台根据第二同步信息进行信息同步更新处理,这保障了同一区块链网络中的不同云平台之间通信的一致性和可靠性,减少通信故障和传输错误。In this step, since the second synchronization information is obtained in step S1120, the second synchronization information can be sent to the second BaaS platform, so that the second BaaS platform performs information synchronization update processing according to the second synchronization information, which ensures the same Consistency and reliability of communication between different cloud platforms in the blockchain network, reducing communication failures and transmission errors.
本实施例中,通过采用上述步骤S1110至步骤S1130,消息中心模块接收第二BaaS平台的包括第二BaaS平台的当前配置信息的第一心跳同步消息,接着根据区块链网络的网络信息对第二BaaS平台的当前配置信息进行对比处理,得到第二同步信息,最后向第二BaaS平台发送第二同步信息,使得第二BaaS平台根据第二同步信息进行信息同步更新处理,保障了同一区块链网络中的不同云平台之间通信的一致性和可靠性,减少通信故障和传输错误。In this embodiment, by adopting the above steps S1110 to S1130, the message center module receives the first heartbeat synchronization message of the second BaaS platform including the current configuration information of the second BaaS platform, and then performs the first heartbeat synchronization message according to the network information of the blockchain network. The current configuration information of the two BaaS platforms is compared and processed to obtain the second synchronization information, and finally the second synchronization information is sent to the second BaaS platform, so that the second BaaS platform performs information synchronization update processing according to the second synchronization information, ensuring the same block Consistency and reliability of communication between different cloud platforms in the blockchain network, reducing communication failures and transmission errors.
在一实施例中,如图13所示,假设第一BaaS平台的消息中心模块为第一消息中心模块,第二BaaS平台的消息中心模块为第二消息中心模块,第一消息中心模块包括第一配置同步模块和第一推送池,第二消息中心模块包括第二配置同步模块和第二推送池,第二配置同步模块对第二BaaS平台的当前配置信息进行封装,并加入到第一心跳同步消息中,接着把第一心跳同步消息发送给第二推送池,第二推送池对该第一心跳同步消息进行定期打包,然后根据根据定时任务,或者消息大小阀值,定期通过从grpc接口向第一BaaS平台的第一推送池发送第一心跳同步消息,第一推送池将第一心跳同步消息转发给第一BaaS平台的第一配置同步模块,第一配置同步模块根据区块链网络的网络信息与第一配置同步模块的当前配置信息进行对比处理,然后把存在差异的配置内容加入到主动同步的第二同步信息中,接着,第一配置同步模块向第一推送池提交第二同步信息,第一推送池通过主grpc接口向第二推送池发送第二同步信息,第二推送池接收到第二同步信息后向第二配置同步模块通知更新同步,第二配置同步模块根据第二同步信息进行信息同步更新处理。In one embodiment, as shown in FIG. 13 , it is assumed that the message center module of the first BaaS platform is the first message center module, the message center module of the second BaaS platform is the second message center module, and the first message center module includes the first message center module. A configuration synchronization module and a first push pool, the second message center module includes a second configuration synchronization module and a second push pool, the second configuration synchronization module encapsulates the current configuration information of the second BaaS platform, and adds it to the first heartbeat In the synchronization message, the first heartbeat synchronization message is then sent to the second push pool, and the second push pool periodically packages the first heartbeat synchronization message, and then periodically passes the slave grpc interface according to the timing task or the message size threshold Send the first heartbeat synchronization message to the first push pool of the first BaaS platform, the first push pool forwards the first heartbeat synchronization message to the first configuration synchronization module of the first BaaS platform, and the first configuration synchronization module according to the block chain network The network information of the first configuration synchronization module is compared with the current configuration information of the first configuration synchronization module, and then the configuration content with differences is added to the second synchronization information of active synchronization. Then, the first configuration synchronization module submits the second configuration information to the first push pool. For synchronization information, the first push pool sends second synchronization information to the second push pool through the main grpc interface, and the second push pool notifies the second configuration synchronization module to update synchronization after receiving the second synchronization information, and the second configuration synchronization module according to the first The second synchronization information performs information synchronization update processing.
在一实施例中,如图14所示,数据通信方法还可以包括但不限于有步骤S1210、步骤S1220和步骤S1230。In an embodiment, as shown in FIG. 14 , the data communication method may further include, but not limited to, step S1210, step S1220, and step S1230.
步骤S1210:接收第三BaaS平台发送的请求信息,请求信息用于表征第三BaaS平台的区块链节点申请加入区块链网络。Step S1210: Receive the request information sent by the third BaaS platform, the request information is used to indicate that the blockchain nodes of the third BaaS platform apply to join the blockchain network.
本步骤中,通过第一BaaS平台的消息中心模块接收第三BaaS平台发送的用于表征第三BaaS平台的区块链节点申请加入区块链网络的请求信息,以便于后续步骤对该请求信息进行验证处理。In this step, the message center module of the first BaaS platform receives the request information sent by the third BaaS platform to represent the block chain node application of the third BaaS platform to join the block chain network, so that the subsequent steps can respond to the request information Perform verification processing.
步骤S1220:对请求信息进行验证处理,当请求信息通过验证,向第三BaaS平台发送加入区块链网络的通知信息,以使第三BaaS平台的区块链节点根据通知信息加入区块链网络。Step S1220: Verify the request information, and when the request information passes the verification, send the notification information of joining the blockchain network to the third BaaS platform, so that the blockchain nodes of the third BaaS platform join the blockchain network according to the notification information .
本步骤中,由于在步骤S1210中接收到了请求信息,因此可以对该请求信息进行验证处理,当请求信息通过验证,则向第三BaaS平台发送加入区块链网络的通知信息,以使第三BaaS平台的区块链节点根据通知信息加入区块链网络,以便于后续步骤通过第一BaaS平台创建的区块链网络,将第一BaaS平台和第三BaaS平台进行数据通信。In this step, since the request information is received in step S1210, the request information can be verified. When the request information passes the verification, the notification information of joining the blockchain network is sent to the third BaaS platform, so that the third The blockchain nodes of the BaaS platform join the blockchain network according to the notification information, so that the subsequent steps can communicate data between the first BaaS platform and the third BaaS platform through the blockchain network created by the first BaaS platform.
步骤S1230:通过区块链网络与第三BaaS平台进行数据通信。Step S1230: Perform data communication with the third BaaS platform through the blockchain network.
本步骤中,由于在步骤S1220中向第三BaaS平台发送了加入区块链网络的通知信息, 因此,通过第一BaaS平台创建的区块链网络,将第一BaaS平台与第三BaaS平台进行数据通信。In this step, since the notification information of joining the blockchain network is sent to the third BaaS platform in step S1220, the first BaaS platform and the third BaaS platform are connected through the blockchain network created by the first BaaS platform. data communication.
本实施例中,通过采用上述S1210至步骤S1230,第一BaaS平台的消息中心模块可以接收第三BaaS平台发送的用于表征第三BaaS平台的区块链节点申请加入区块链网络的请求信息,然后对该请求信息进行验证,当请求信息通过验证,向第三BaaS平台发送加入区块链网络的通知信息,最终通过第一BaaS平台创建的区块链网络,将第一BaaS平台第三BaaS平台进行数据通信,即是说,本申请实施例的方案能够实现在不同云平台、不同区域之间协同组网,因此,本申请实施例的方案能够实现不同云平台之间的数据交换和资源共享,以达到跨平台通讯目的。In this embodiment, by adopting the above steps from S1210 to S1230, the message center module of the first BaaS platform can receive the request information sent by the third BaaS platform to represent the application of the blockchain node of the third BaaS platform to join the blockchain network , and then verify the request information. When the request information passes the verification, a notification message to join the blockchain network is sent to the third BaaS platform, and finally through the blockchain network created by the first BaaS platform, the first BaaS platform third The BaaS platform performs data communication, that is to say, the scheme of the embodiment of the present application can realize collaborative networking between different cloud platforms and different regions, therefore, the scheme of the embodiment of the present application can realize data exchange and communication between different cloud platforms. Resource sharing to achieve cross-platform communication purposes.
在一实施例中,第三BaaS平台将请求信息放入第三BaaS平台的心跳池的请求队列里,对该请求队列进行打包,发送给第三BaaS平台的通讯层,通过grpc协议根据目的地址发送给第一BaaS平台的通讯层,第一BaaS平台的通讯层接收到请求信息后发送到第一BaaS平台的心跳池的接收队列里,接收队列向第一BaaS平台的接口层请求分发请求信息,接着接口层向第一BaaS平台的网络管理模块发送该请求信息,第一BaaS平台的网络管理模块请求信息进行验证处理,如果请求信息通过验证,向第三BaaS平台发送加入区块链网络的通知信息,第三BaaS平台的区块链节点根据通知信息加入区块链网络,最终第一BaaS平台通过区块链网络与第三BaaS平台进行数据通信。In one embodiment, the third BaaS platform puts the request information into the request queue of the heartbeat pool of the third BaaS platform, packs the request queue, sends it to the communication layer of the third BaaS platform, and uses the grpc protocol according to the destination address Send to the communication layer of the first BaaS platform. After receiving the request information, the communication layer of the first BaaS platform sends it to the receiving queue of the heartbeat pool of the first BaaS platform. The receiving queue requests the interface layer of the first BaaS platform to distribute the request information , and then the interface layer sends the request information to the network management module of the first BaaS platform, and the network management module of the first BaaS platform requests information for verification processing. If the request information passes the verification, it sends the request information to the third BaaS platform to join the blockchain network Notification information, the blockchain node of the third BaaS platform joins the blockchain network according to the notification information, and finally the first BaaS platform performs data communication with the third BaaS platform through the blockchain network.
在一实施例中,如图15所示,数据通信方法还可以包括但不限于有步骤S1310。In an embodiment, as shown in FIG. 15 , the data communication method may further include but not limited to step S1310.
步骤S1310:根据区块链网络的网络信息对第三BaaS平台进行信息同步更新处理。Step S1310: Perform information synchronization update processing on the third BaaS platform according to the network information of the blockchain network.
本实施例中,由于在上述步骤中第一BaaS平台已经通过区块链网络与第三BaaS平台进行数据通信,因此,可以根据区块链网络的网络信息对第三BaaS平台进行信息同步更新处理,这保障了同一区块链网络中的不同云平台之间通信的一致性和可靠性,减少通信故障和传输错误。In this embodiment, since the first BaaS platform has performed data communication with the third BaaS platform through the blockchain network in the above steps, the information synchronization update process can be performed on the third BaaS platform according to the network information of the blockchain network , which ensures the consistency and reliability of communication between different cloud platforms in the same blockchain network, reducing communication failures and transmission errors.
需要说明的是,同步更新的方式可以包括主动同步和心跳同步等,在此不做具体限制。It should be noted that, the ways of synchronizing and updating may include active synchronization and heartbeat synchronization, etc., which are not specifically limited here.
在一实施例中,如图16所示,对步骤S1310进一步的说明,该步骤S1310可以包括但不限于有步骤S1410、步骤S1420和步骤S1430。In an embodiment, as shown in FIG. 16 , step S1310 is further described, and step S1310 may include but not limited to step S1410 , step S1420 and step S1430 .
步骤S1410:根据区块链网络的网络信息得到第二配置更新信息。Step S1410: Obtain the second configuration update information according to the network information of the blockchain network.
本步骤中,由于在步骤S730中已经部署了区块链网络,因此可以根据区块链网络的网络信息得到第二配置更新信息,以便于后续步骤对该第二配置更新信息进行打包处理。In this step, since the blockchain network has been deployed in step S730, the second configuration update information can be obtained according to the network information of the blockchain network, so as to package the second configuration update information in subsequent steps.
需要说明的是,第二配置更新信息是第一BaaS平台的配置信息。It should be noted that the second configuration update information is configuration information of the first BaaS platform.
步骤S1420:对第二配置更新信息进行打包处理,得到第三同步信息。Step S1420: Packetize the second configuration update information to obtain third synchronization information.
本步骤中,由于在步骤S1410中得到了第二配置更新信息,因此,可以对第二配置更新信息进行打包处理,得到第三同步消息,以便于后续步骤可以向第三BaaS平台发送第三同步信息,使得第三BaaS平台根据第三同步信息进行信息同步更新处理。In this step, since the second configuration update information is obtained in step S1410, the second configuration update information can be packaged to obtain a third synchronization message, so that the subsequent steps can send the third synchronization message to the third BaaS platform Information, so that the third BaaS platform performs information synchronization update processing according to the third synchronization information.
需要说明的是,可以对第二配置更新信息进行定期打包,可以根据实际情况决定,在此不作具体限定。It should be noted that the second configuration update information may be packaged periodically, which may be determined according to actual conditions, and is not specifically limited here.
步骤S1430:向第三BaaS平台发送第三同步信息,使得第三BaaS平台根据第三同步信息进行信息同步更新处理。Step S1430: Send third synchronization information to the third BaaS platform, so that the third BaaS platform performs information synchronization update processing according to the third synchronization information.
本步骤中,由于在步骤S1420中得到了第三同步信息,因此,可以向第三BaaS平台发送第三同步信息,使得第三BaaS平台根据第三同步信息进行信息同步更新处理,这保障了同一区块链网络中的不同云平台之间通信的一致性和可靠性,减少通信故障和传输错误。In this step, since the third synchronization information is obtained in step S1420, the third synchronization information can be sent to the third BaaS platform, so that the third BaaS platform performs information synchronization update processing according to the third synchronization information, which ensures the same Consistency and reliability of communication between different cloud platforms in the blockchain network, reducing communication failures and transmission errors.
本实施例中,通过采用上述步骤S1410至步骤S1430,根据区块链网络的网络信息得到第二配置更新信息,接着又对第二配置更新信息进行打包处理,得到第三同步信息,最后向第三BaaS平台发送第三同步信息,使得第三BaaS平台根据第三同步信息进行信息同步更新处理,从而保障了同一区块链网络中的不同云平台之间通信的一致性和可靠性,减少通信故障和传输错误。In this embodiment, by using the above steps S1410 to S1430, the second configuration update information is obtained according to the network information of the blockchain network, and then the second configuration update information is packaged to obtain the third synchronization information, and finally sent to the second The third BaaS platform sends the third synchronization information, so that the third BaaS platform performs information synchronization update processing according to the third synchronization information, thereby ensuring the consistency and reliability of communication between different cloud platforms in the same blockchain network and reducing communication glitches and transmission errors.
在一实施例中,假设第一BaaS平台的消息中心模块为第一消息中心模块,第三BaaS平台的消息中心模块为第三消息中心模块,第一消息中心模块包括第一配置同步模块和第一推送池,第三消息中心模块包括第三配置同步模块和第三推送池,第一配置同步模块根据区块链网络的网络信息得到第二配置更新信息,并发送给第一推送池,第一推送池对该第二配置更新信息进行定期打包,得到第三同步信息,然后第一推送池通过推送消息(或者主grpc接口)对该第三同步信息加入推送同步列表中,接着将该推送同步列表中的第三同步信息发送给第三推送池,第三推送池向第三配置同步模块通知更新同步,第三配置同步模块对第三BaaS平台进行同步更新。In one embodiment, it is assumed that the message center module of the first BaaS platform is the first message center module, the message center module of the third BaaS platform is the third message center module, and the first message center module includes the first configuration synchronization module and the second message center module. A push pool, the third message center module includes a third configuration synchronization module and a third push pool, the first configuration synchronization module obtains the second configuration update information according to the network information of the blockchain network, and sends it to the first push pool, the second A push pool regularly packages the second configuration update information to obtain the third synchronization information, and then the first push pool adds the third synchronization information to the push synchronization list through a push message (or main grpc interface), and then pushes the The third synchronization information in the synchronization list is sent to the third push pool, and the third push pool notifies the update synchronization to the third configuration synchronization module, and the third configuration synchronization module performs synchronization update on the third BaaS platform.
需要说明的是,第三BaaS平台可以启动监听事件,通过广播发送的方式获取第二配置更新信息,进行同步更新。除此之外,第三BaaS平台也可以采用其他方式获取第二配置更新信息,比如单播、组播等等,在此不做具体限制。It should be noted that the third BaaS platform can start monitoring events, obtain the second configuration update information by broadcasting, and perform synchronous updates. In addition, the third BaaS platform may also obtain the second configuration update information in other ways, such as unicast, multicast, etc., which are not specifically limited here.
在另一实施例中,如图17所示,对步骤S1310进一步的说明,该步骤S1310可以包括但不限于有步骤S1510、步骤S1520和步骤S1530。In another embodiment, as shown in FIG. 17 , step S1310 is further described, and step S1310 may include but not limited to step S1510 , step S1520 and step S1530 .
步骤S1510:接收第三BaaS平台的第二心跳同步消息,第二心跳同步消息包括第三BaaS平台的当前配置信息。Step S1510: Receive a second heartbeat synchronization message of the third BaaS platform, where the second heartbeat synchronization message includes current configuration information of the third BaaS platform.
本步骤中,消息中心模块接收第三BaaS平台的包括第三BaaS平台的当前配置信息的第二心跳同步消息,以便于后续步骤根据区块链网络的网络信息对第三BaaS平台的当前配置信息进行对比处理。In this step, the message center module receives the second heartbeat synchronization message of the third BaaS platform including the current configuration information of the third BaaS platform, so that the subsequent steps can update the current configuration information of the third BaaS platform according to the network information of the block chain network for comparison.
需要说明的是,第三BaaS平台的当前配置信息可以包括网络、通道、组织、节点或者是链码的配置列表,配置列表可以包括ID和哈希值等,在此不作具体限定。It should be noted that the current configuration information of the third BaaS platform may include a configuration list of networks, channels, organizations, nodes, or chaincodes, and the configuration list may include IDs and hash values, which are not specifically limited here.
步骤S1520:根据区块链网络的网络信息对第三BaaS平台的当前配置信息进行对比处理,得到第四同步信息。Step S1520: Compare and process the current configuration information of the third BaaS platform according to the network information of the blockchain network to obtain fourth synchronization information.
本步骤中,由于在步骤S1510中得到了包括第三BaaS平台的当前配置信息的第二心跳同步消息,因此,可以根据区块链网络的网络信息对第三BaaS平台的当前配置信息进行对比处理,得到第四同步信息,以便于后续步骤向第三BaaS平台发送第四同步信息,使得第三BaaS平台根据第四同步信息进行信息同步更新处理。In this step, since the second heartbeat synchronization message including the current configuration information of the third BaaS platform is obtained in step S1510, the current configuration information of the third BaaS platform can be compared according to the network information of the blockchain network , to obtain the fourth synchronization information, so as to send the fourth synchronization information to the third BaaS platform in a subsequent step, so that the third BaaS platform performs information synchronization update processing according to the fourth synchronization information.
步骤S1530:向第三BaaS平台发送第四同步信息,使得第三BaaS平台根据第四同步信息进行信息同步更新处理。Step S1530: Send fourth synchronization information to the third BaaS platform, so that the third BaaS platform performs information synchronization update processing according to the fourth synchronization information.
本步骤中,由于在步骤S1520中得到了第四同步信息,因此,可以向第三BaaS平台发送第四同步信息,使得第三BaaS平台根据第四同步信息进行信息同步更新处理,这保障了同 一区块链网络中的不同云平台之间通信的一致性和可靠性,减少通信故障和传输错误。In this step, since the fourth synchronization information is obtained in step S1520, the fourth synchronization information can be sent to the third BaaS platform, so that the third BaaS platform performs information synchronization update processing according to the fourth synchronization information, which ensures the same Consistency and reliability of communication between different cloud platforms in the blockchain network, reducing communication failures and transmission errors.
本实施例中,通过采用上述步骤S1510至步骤S1530,消息中心模块接收第三BaaS平台的包括第三BaaS平台的当前配置信息的第二心跳同步消息,接着根据区块链网络的网络信息对第三BaaS平台的当前配置信息进行对比处理,得到第四同步信息,最后向第三BaaS平台发送第四同步信息,使得第三BaaS平台根据第四同步信息进行信息同步更新处理,保障了同一区块链网络中的不同云平台之间通信的一致性和可靠性,减少通信故障和传输错误。In this embodiment, by adopting the above steps S1510 to S1530, the message center module receives the second heartbeat synchronization message of the third BaaS platform including the current configuration information of the third BaaS platform, and then performs the second heartbeat synchronization message according to the network information of the blockchain network. The current configuration information of the three BaaS platforms is compared and processed to obtain the fourth synchronization information, and finally the fourth synchronization information is sent to the third BaaS platform, so that the third BaaS platform performs information synchronization update processing according to the fourth synchronization information, ensuring the same block Consistency and reliability of communication between different cloud platforms in the blockchain network, reducing communication failures and transmission errors.
在一实施例中,假设第一BaaS平台的消息中心模块为第一消息中心模块,第三BaaS平台的消息中心模块为第三消息中心模块,第一消息中心模块包括第一配置同步模块和第一推送池,第三消息中心模块包括第三配置同步模块和第三推送池,第三配置同步模块对第三BaaS平台的当前配置信息进行封装,并加入到第二心跳同步消息中,接着把第二心跳同步消息发送给第三推送池,第三推送池对该第二心跳同步消息进行定期打包,然后根据根据定时任务,或者消息大小阀值,定期通过从grpc接口向第一BaaS平台的第一配置同步模块发送第二心跳同步消息,第一推送池转发给第一BaaS平台的第一配置同步模块,第一配置同步模块根据区块链网络的网络信息与第一配置同步模块的当前配置信息进行对比处理,然后把存在差异的配置内容加入到主动同步的第四同步信息中,接着,第一配置同步模块向第一推送池提交第四同步信息,第一推送池通过主grpc接口向第三推送池发送第四同步信息,第三推送池接收到第四同步信息后向第三配置同步模块通知更新同步,第三配置同步模块根据第四同步信息进行信息同步更新处理。In one embodiment, it is assumed that the message center module of the first BaaS platform is the first message center module, the message center module of the third BaaS platform is the third message center module, and the first message center module includes the first configuration synchronization module and the second message center module. A push pool, the third message center module includes a third configuration synchronization module and a third push pool, the third configuration synchronization module encapsulates the current configuration information of the third BaaS platform, and adds it to the second heartbeat synchronization message, and then sends the The second heartbeat synchronization message is sent to the third push pool, and the third push pool regularly packs the second heartbeat synchronization message, and then periodically transmits the message from the grpc interface to the first BaaS platform according to the timing task or the message size threshold. The first configuration synchronization module sends the second heartbeat synchronization message, and the first push pool forwards it to the first configuration synchronization module of the first BaaS platform. The configuration information is compared and processed, and then the configuration content with differences is added to the fourth synchronization information of active synchronization. Then, the first configuration synchronization module submits the fourth synchronization information to the first push pool, and the first push pool passes the main grpc interface The fourth synchronization information is sent to the third push pool, and after receiving the fourth synchronization information, the third push pool notifies the third configuration synchronization module of update synchronization, and the third configuration synchronization module performs information synchronization update processing according to the fourth synchronization information.
另外,本申请的实施例还提供了一种数据通信装置200,如图18所示,该数据通信装置200包括但不限于:In addition, the embodiment of the present application also provides a data communication device 200, as shown in Figure 18, the data communication device 200 includes but is not limited to:
存储器202,用于存储程序; memory 202, for storing programs;
处理器201,用于执行存储器202存储的程序,当处理器201执行存储器202存储的程序时,处理器201用于执行上述的数据通信方法。The processor 201 is configured to execute the program stored in the memory 202. When the processor 201 executes the program stored in the memory 202, the processor 201 is configured to execute the above data communication method.
处理器201和存储器202可以通过总线或者其他方式连接。The processor 201 and the memory 202 may be connected through a bus or other means.
存储器202作为一种非暂态计算机可读存储介质,可用于存储非暂态软件程序以及非暂态性计算机可执行程序,如本申请实施例描述的数据通信方法。处理器201通过运行存储在存储器202中的非暂态软件程序以及指令,从而实现上述的数据通信方法。The memory 202, as a non-transitory computer-readable storage medium, can be used to store non-transitory software programs and non-transitory computer-executable programs, such as the data communication method described in the embodiment of the present application. The processor 201 implements the above-mentioned data communication method by running the non-transitory software programs and instructions stored in the memory 202 .
存储器202可以包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需要的应用程序;存储数据区可存储执行上述的数据通信方法。此外,存储器202可以包括高速随机存取存储器,还可以包括非暂态存储器,例如至少一个磁盘存储器件、闪存器件、或其他非暂态固态存储器件。在一些实施方式中,存储器202可选包括相对于处理器201远程设置的存储器202,这些远程存储器可以通过网络连接至该处理器201。上述网络的实例包括但不限于互联网、企业内部网、局域网、移动通信网及其组合。The memory 202 may include a program storage area and a data storage area, wherein the program storage area may store an operating system and an application program required by at least one function; the data storage area may store and execute the above-mentioned data communication method. In addition, the memory 202 may include a high-speed random access memory, and may also include a non-transitory memory, such as at least one magnetic disk storage device, a flash memory device, or other non-transitory solid-state storage devices. In some implementations, the memory 202 may optionally include memory 202 remotely located relative to the processor 201, and these remote memories may be connected to the processor 201 through a network. Examples of the aforementioned networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.
实现上述的数据通信方法所需的非暂态软件程序以及指令存储在存储器202中,当被一个或者多个处理器201执行时,执行上述的数据通信方法,例如,执行以上描述的图6中的方法步骤S610至步骤S650、图7中的方法步骤S710至步骤S730、图8中的方法步骤S810至步骤S830、图9中的方法步骤S910、图10中的方法步骤S1010至步骤S1030、图12中的方法步骤S1110至步骤S1130、图14中的方法步骤S1210至步骤S1230、图15中的方法步骤 S1310、图16中的方法步骤S1410至步骤S1430以及图17中的方法步骤S1510至步骤S1530。The non-transitory software programs and instructions required to realize the above-mentioned data communication method are stored in the memory 202, and when executed by one or more processors 201, the above-mentioned data communication method is executed, for example, the above-described execution in FIG. 6 is executed. method step S610 to step S650, method step S710 to step S730 in FIG. 7, method step S810 to step S830 in FIG. 8, method step S910 in FIG. 9, method step S1010 to step S1030 in FIG. Method step S1110 to step S1130 in 12, method step S1210 to step S1230 in FIG. 14 , method step S1310 in FIG. 15 , method step S1410 to step S1430 in FIG. 16 and method step S1510 to step S1530 in FIG. 17 .
以上所描述的装置实施例或者系统实施例仅仅是示意性的,其中作为分离部件说明的单元可以是或者也可以不是物理上分开的,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部模块来实现本实施例方案的目的。The above-described device embodiments or system embodiments are only illustrative, and the units described as separate components may or may not be physically separated, that is, they may be located in one place, or may be distributed to multiple network units superior. Part or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
本申请的一个实施例还提供了一种计算机可读存储介质,该计算机可读存储介质存储有计算机可执行指令,该计算机可执行指令被一个处理器或控制器执行,例如,被上述装置实施例中的一个处理器执行,可使得上述处理器执行上述实施例中的数据通信方法,例如,执行以上描述的图6中的方法步骤S610至步骤S650、图7中的方法步骤S710至步骤S730、图8中的方法步骤S810至步骤S830、图9中的方法步骤S910、图10中的方法步骤S1010至步骤S1030、图12中的方法步骤S1110至步骤S1130、图14中的方法步骤S1210至步骤S1230、图15中的方法步骤S1310、图16中的方法步骤S1410至步骤S1430以及图17中的方法步骤S1510至步骤S1530。An embodiment of the present application also provides a computer-readable storage medium, the computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are executed by a processor or a controller, for example, implemented by the above-mentioned device Execution by a processor in the example can cause the above-mentioned processor to execute the data communication method in the above-mentioned embodiment, for example, execute the method steps S610 to S650 in FIG. 6 and the method steps S710 to S730 in FIG. 7 described above. , method step S810 to step S830 in Fig. 8, method step S910 in Fig. 9, method step S1010 to step S1030 in Fig. 10, method step S1110 to step S1130 in Fig. 12, method step S1210 to step S1130 in Fig. 14 Step S1230, method step S1310 in FIG. 15, method step S1410 to step S1430 in FIG. 16, and method step S1510 to step S1530 in FIG. 17.
此外,本申请的一个实施例还提供了一种计算机程序产品,包括计算机程序或计算机指令,计算机程序或计算机指令存储在计算机可读存储介质中,计算机设备的处理器从计算机可读存储介质读取计算机程序或计算机指令,处理器执行计算机程序或计算机指令,使得计算机设备执行上述实施例中的数据通信方法,例如,执行以上描述的图6中的方法步骤S610至步骤S650、图7中的方法步骤S710至步骤S730、图8中的方法步骤S810至步骤S830、图9中的方法步骤S910、图10中的方法步骤S1010至步骤S1030、图12中的方法步骤S1110至步骤S1130、图14中的方法步骤S1210至步骤S1230、图15中的方法步骤S1310、图16中的方法步骤S1410至步骤S1430以及图17中的方法步骤S1510至步骤S1530。In addition, an embodiment of the present application also provides a computer program product, including computer programs or computer instructions, where the computer programs or computer instructions are stored in a computer-readable storage medium, and the processor of the computer device reads the computer program from the computer-readable storage medium. Take the computer program or computer instruction, the processor executes the computer program or computer instruction, so that the computer device executes the data communication method in the above-mentioned embodiment, for example, executes the method step S610 to step S650 in FIG. 6 described above, and the method in FIG. 7 Method step S710 to step S730, method step S810 to step S830 in Fig. 8, method step S910 in Fig. 9, method step S1010 to step S1030 in Fig. 10, method step S1110 to step S1130 in Fig. 12, Fig. 14 The method step S1210 to step S1230 in FIG. 15 , the method step S1310 in FIG. 15 , the method step S1410 to step S1430 in FIG. 16 , and the method step S1510 to step S1530 in FIG. 17 .
本申请实施例包括:部署区块链网络;向第二BaaS平台发送邀请信息,邀请信息用于邀请第二BaaS平台的区块链节点进入区块链网络;接收第二BaaS平台根据邀请信息发送的反馈信息;当反馈信息表征第二BaaS平台的区块链节点同意加入区块链网络,将第二BaaS平台加入的区块链节点到区块链网络;通过区块链网络与第二BaaS平台进行数据通信。根据本申请实施例的方案,通过向第二BaaS平台发送用于邀请第二BaaS平台的区块链节点进入区块链网络的邀请信息,接收第二BaaS平台根据邀请信息发送的反馈信息,然后再对反馈信息进行验证,当反馈信息表征第二BaaS平台的区块链节点同意加入区块链网络,就将第二BaaS平台的区块链节点加入到区块链网络,最后通过第一BaaS平台创建的区块链网络,将第一BaaS平台与第二BaaS平台进行数据通信,即是说,本申请实施例的方案能够实现在不同云平台、不同区域之间协同组网,因此能够实现不同云平台之间的数据交换和资源共享,以达到跨平台通讯目的。The embodiment of this application includes: deploying a blockchain network; sending invitation information to the second BaaS platform, the invitation information is used to invite the blockchain nodes of the second BaaS platform to enter the blockchain network; receiving the second BaaS platform according to the invitation information sent Feedback information; when the feedback information indicates that the blockchain node of the second BaaS platform agrees to join the blockchain network, the blockchain node joined by the second BaaS platform will be added to the blockchain network; through the blockchain network and the second BaaS platform for data communication. According to the scheme of the embodiment of the present application, by sending the invitation information for inviting the blockchain node of the second BaaS platform to enter the blockchain network to the second BaaS platform, receiving the feedback information sent by the second BaaS platform according to the invitation information, and then Then verify the feedback information. When the feedback information indicates that the blockchain node of the second BaaS platform agrees to join the blockchain network, the blockchain node of the second BaaS platform will be added to the blockchain network, and finally through the first BaaS platform. The blockchain network created by the platform communicates data between the first BaaS platform and the second BaaS platform. Data exchange and resource sharing between different cloud platforms to achieve cross-platform communication.
本领域普通技术人员可以理解,上文中所公开方法中的全部或某些步骤、系统可以被实施为软件、固件、硬件及其适当的组合。某些物理组件或所有物理组件可以被实施为由处理器,如中央处理器、数字信号处理器或微处理器执行的软件,或者被实施为硬件,或者被实施为集成电路,如专用集成电路。这样的软件可以分布在计算机可读介质上,计算机可读介质可以包括计算机存储介质(或非暂时性介质)和通信介质(或暂时性介质)。如本领域普通技术人员公知的,术语计算机存储介质包括在用于存储信息(诸如计算机可读指令、数据结构、程序模块或其他数据)的任何方法或技术中实施的易失性和非易失性、可移除和不可移 除介质。计算机存储介质包括但不限于RAM、ROM、EEPROM、闪存或其他存储器技术、CD-ROM、数字多功能盘(DVD)或其他光盘存储、磁盒、磁带、磁盘存储或其他磁存储装置、或者可以用于存储期望的信息并且可以被计算机访问的任何其他的介质。此外,本领域普通技术人员公知的是,通信介质通常包含计算机可读指令、数据结构、程序模块或者诸如载波或其他传输机制之类的调制数据信号中的其他数据,并且可包括任何信息递送介质。Those skilled in the art can understand that all or some of the steps and systems in the methods disclosed above can be implemented as software, firmware, hardware and an appropriate combination thereof. Some or all of the physical components may be implemented as software executed by a processor, such as a central processing unit, digital signal processor, or microprocessor, or as hardware, or as an integrated circuit, such as an application-specific integrated circuit . Such software may be distributed on computer readable media, which may include computer storage media (or non-transitory media) and communication media (or transitory media). As known to those of ordinary skill in the art, the term computer storage media includes both volatile and nonvolatile media implemented in any method or technology for storage of information, such as computer readable instructions, data structures, program modules, or other data. permanent, removable and non-removable media. Computer storage media includes, but is not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital versatile disk (DVD) or other optical disk storage, magnetic cartridges, tape, magnetic disk storage or other magnetic storage devices, or can Any other medium used to store desired information and which can be accessed by a computer. In addition, as is well known to those of ordinary skill in the art, communication media typically embodies computer readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transport mechanism, and may include any information delivery media .
以上是对本申请的若干实施进行了具体说明,但本申请并不局限于上述实施方式,熟悉本领域的技术人员在不违背本申请本质的前提下还可作出种种的等同变形或替换,这些等同的变形或替换均包含在本申请权利要求所限定的范围内。The above is a specific description of several implementations of the present application, but the present application is not limited to the above-mentioned embodiments. Those skilled in the art can also make various equivalent deformations or replacements without violating the essence of the present application. Any modification or substitution is included within the scope defined by the claims of the present application.
Claims (13)
- 一种数据通信方法,应用于第一区块链服务BaaS平台,所述数据通信方法包括:A data communication method applied to the first blockchain service BaaS platform, the data communication method comprising:部署区块链网络;Deploy the blockchain network;向第二BaaS平台发送邀请信息,所述邀请信息用于邀请所述第二BaaS平台的区块链节点进入所述区块链网络;sending invitation information to the second BaaS platform, where the invitation information is used to invite the blockchain nodes of the second BaaS platform to enter the blockchain network;接收所述第二BaaS平台根据所述邀请信息发送的反馈信息;receiving feedback information sent by the second BaaS platform according to the invitation information;当所述反馈信息表征所述第二BaaS平台的区块链节点同意加入所述区块链网络,将所述第二BaaS平台的区块链节点加入到所述区块链网络;When the feedback information indicates that the blockchain node of the second BaaS platform agrees to join the blockchain network, adding the blockchain node of the second BaaS platform to the blockchain network;通过所述区块链网络与所述第二BaaS平台进行数据通信。Perform data communication with the second BaaS platform through the block chain network.
- 根据权利要求1所述的数据通信方法,其中,所述部署区块链网络,包括:The data communication method according to claim 1, wherein said deploying a blockchain network comprises:选择目标区块链引擎和区域;Select the target blockchain engine and region;对所述区域进行配置处理,得到区域信息;performing configuration processing on the area to obtain area information;根据所述目标区块链引擎和所述区域信息部署区块链网络。Deploying a blockchain network according to the target blockchain engine and the region information.
- 根据权利要求1所述的数据通信方法,其中,所述向第二BaaS平台发送邀请信息,包括:The data communication method according to claim 1, wherein the sending invitation information to the second BaaS platform includes:根据所述区块链网络的网络信息生成邀请信息;generating invitation information according to the network information of the blockchain network;对所述邀请信息进行封装处理得到封装后的邀请信息;Encapsulating the invitation information to obtain the encapsulated invitation information;向第二BaaS平台发送所述封装后的邀请信息。Send the encapsulated invitation information to the second BaaS platform.
- 根据权利要求3所述的数据通信方法,还包括:The data communication method according to claim 3, further comprising:根据所述区块链网络的网络信息对所述第二BaaS平台进行信息同步更新处理。Perform information synchronization update processing on the second BaaS platform according to the network information of the blockchain network.
- 根据权利要求4所述的数据通信方法,其中,所述根据所述区块链网络的网络信息对所述第二BaaS平台进行信息同步更新处理,包括:The data communication method according to claim 4, wherein, performing information synchronization update processing on the second BaaS platform according to the network information of the blockchain network includes:根据所述区块链网络的网络信息得到第一配置更新信息;obtaining first configuration update information according to the network information of the blockchain network;对所述第一配置更新信息进行打包处理,得到第一同步信息;performing packaging processing on the first configuration update information to obtain first synchronization information;向所述第二BaaS平台发送所述第一同步信息,使得所述第二BaaS平台根据所述第一同步信息进行信息同步更新处理。Sending the first synchronization information to the second BaaS platform, so that the second BaaS platform performs information synchronization update processing according to the first synchronization information.
- 根据权利要求4所述的数据通信方法,其中,所述根据所述区块链网络的网络信息对所述第二BaaS平台进行信息同步更新处理,还包括:The data communication method according to claim 4, wherein, performing information synchronization update processing on the second BaaS platform according to the network information of the blockchain network, further comprising:接收所述第二BaaS平台的第一心跳同步消息,所述第一心跳同步消息包括所述第二BaaS平台的当前配置信息;Receive a first heartbeat synchronization message of the second BaaS platform, where the first heartbeat synchronization message includes current configuration information of the second BaaS platform;根据区块链网络的网络信息对所述第二BaaS平台的当前配置信息进行对比处理,得到第二同步信息;According to the network information of the block chain network, the current configuration information of the second BaaS platform is compared and processed to obtain the second synchronization information;向所述第二BaaS平台发送所述第二同步信息,使得所述第二BaaS平台根据所述第二同步信息进行信息同步更新处理。Sending the second synchronization information to the second BaaS platform, so that the second BaaS platform performs information synchronization update processing according to the second synchronization information.
- 根据权利要求1所述的数据通信方法,还包括:The data communication method according to claim 1, further comprising:接收第三BaaS平台发送的请求信息,所述请求信息用于表征所述第三BaaS平台的区块链节点申请加入所述区块链网络;Receive request information sent by the third BaaS platform, the request information is used to indicate that the blockchain node of the third BaaS platform applies to join the blockchain network;对所述请求信息进行验证处理,当所述请求信息通过验证,向所述第三BaaS平台发送加 入所述区块链网络的通知信息,以使所述第三BaaS平台的区块链节点根据所述通知信息加入所述区块链网络;Perform verification processing on the request information, and when the request information passes the verification, send notification information to the third BaaS platform to join the blockchain network, so that the blockchain nodes of the third BaaS platform The notification information is added to the blockchain network;通过所述区块链网络与所述第三BaaS平台进行数据通信。Perform data communication with the third BaaS platform through the block chain network.
- 根据权利要求7所述的数据通信方法,还包括:The data communication method according to claim 7, further comprising:根据所述区块链网络的网络信息对所述第三BaaS平台进行信息同步更新处理。Perform information synchronization update processing on the third BaaS platform according to the network information of the blockchain network.
- 根据权利要求8所述的数据通信方法,其中,所述根据所述区块链网络的网络信息对所述第三BaaS平台进行信息同步更新处理,包括:The data communication method according to claim 8, wherein, performing information synchronization update processing on the third BaaS platform according to the network information of the blockchain network includes:根据所述区块链网络的网络信息得到第二配置更新信息;obtaining second configuration update information according to the network information of the blockchain network;对所述第二配置更新信息进行打包处理,得到第三同步信息;performing packaging processing on the second configuration update information to obtain third synchronization information;向所述第三BaaS平台发送所述第三同步信息,使得所述第三BaaS平台根据所述第三同步信息进行信息同步更新处理。Sending the third synchronization information to the third BaaS platform, so that the third BaaS platform performs information synchronization update processing according to the third synchronization information.
- 根据权利要求8所述的数据通信方法,其中,所述根据所述区块链网络的网络信息对所述第三BaaS平台进行信息同步更新处理,还包括:The data communication method according to claim 8, wherein, performing information synchronization update processing on the third BaaS platform according to the network information of the blockchain network, further comprising:接收所述第三BaaS平台的第二心跳同步消息,所述第二心跳同步消息包括所述第三BaaS平台的当前配置信息;Receive a second heartbeat synchronization message of the third BaaS platform, where the second heartbeat synchronization message includes current configuration information of the third BaaS platform;根据区块链网络的网络信息对所述第三BaaS平台的当前配置信息进行对比处理,得到第四同步信息;According to the network information of the block chain network, the current configuration information of the third BaaS platform is compared and processed to obtain the fourth synchronization information;向所述第三BaaS平台发送所述第四同步信息,使得所述第三BaaS平台根据所述第四同步信息进行信息同步更新处理。Sending the fourth synchronization information to the third BaaS platform, so that the third BaaS platform performs information synchronization update processing according to the fourth synchronization information.
- 一种数据通信装置,包括:存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,其中,所述处理器执行所述计算机程序时实现如权利要求1至10任意一项所述的数据通信方法。A data communication device, comprising: a memory, a processor, and a computer program stored in the memory and operable on the processor, wherein, when the processor executes the computer program, any one of claims 1 to 10 is realized The data communication method described.
- 一种计算机可读存储介质,存储有计算机可执行指令,所述计算机可执行指令用于执行权利要求1至10任意一项所述的数据通信方法。A computer-readable storage medium storing computer-executable instructions for executing the data communication method according to any one of claims 1-10.
- 一种计算机程序产品,包括计算机程序或计算机指令,其中,所述计算机程序或所述计算机指令存储在计算机可读存储介质中,计算机设备的处理器从所述计算机可读存储介质读取所述计算机程序或所述计算机指令,所述处理器执行所述计算机程序或所述计算机指令,使得所述计算机设备执行如权利要求1至10任意一项所述的数据通信方法。A computer program product comprising a computer program or computer instructions, wherein the computer program or the computer instructions are stored in a computer-readable storage medium, and a processor of a computer device reads the computer-readable storage medium from the computer-readable storage medium A computer program or the computer instruction, the processor executes the computer program or the computer instruction, so that the computer device executes the data communication method according to any one of claims 1 to 10.
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111386056.1A CN116155518A (en) | 2021-11-22 | 2021-11-22 | Data communication method and device, storage medium, and program product |
CN202111386056.1 | 2021-11-22 |
Publications (1)
Publication Number | Publication Date |
---|---|
WO2023088135A1 true WO2023088135A1 (en) | 2023-05-25 |
Family
ID=86339446
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
PCT/CN2022/130609 WO2023088135A1 (en) | 2021-11-22 | 2022-11-08 | Data communication method and apparatus thereof, storage medium and program product |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN116155518A (en) |
WO (1) | WO2023088135A1 (en) |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109246179A (en) * | 2018-06-30 | 2019-01-18 | 华为技术有限公司 | Safeguard method and apparatus, server and the computer readable storage medium of block chain |
CN110572398A (en) * | 2019-09-10 | 2019-12-13 | 腾讯科技(深圳)有限公司 | block chain network control method, device, equipment and storage medium |
US20200169534A1 (en) * | 2018-11-23 | 2020-05-28 | Amazon Technologies, Inc. | Enabling access across private networks for a managed blockchain service |
CN111628886A (en) * | 2020-04-14 | 2020-09-04 | 苏宁金融科技(南京)有限公司 | Method and device for building block chain network under private cloud environment, and computer equipment |
-
2021
- 2021-11-22 CN CN202111386056.1A patent/CN116155518A/en active Pending
-
2022
- 2022-11-08 WO PCT/CN2022/130609 patent/WO2023088135A1/en unknown
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109246179A (en) * | 2018-06-30 | 2019-01-18 | 华为技术有限公司 | Safeguard method and apparatus, server and the computer readable storage medium of block chain |
US20200169534A1 (en) * | 2018-11-23 | 2020-05-28 | Amazon Technologies, Inc. | Enabling access across private networks for a managed blockchain service |
CN110572398A (en) * | 2019-09-10 | 2019-12-13 | 腾讯科技(深圳)有限公司 | block chain network control method, device, equipment and storage medium |
CN111628886A (en) * | 2020-04-14 | 2020-09-04 | 苏宁金融科技(南京)有限公司 | Method and device for building block chain network under private cloud environment, and computer equipment |
Also Published As
Publication number | Publication date |
---|---|
CN116155518A (en) | 2023-05-23 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN113259455B (en) | Cross-subnet interaction method and device | |
CN111934996B (en) | Message transmission method and device | |
CN113259460B (en) | Cross-chain interaction method and device | |
CN113259456B (en) | Cross-chain interaction method and device | |
WO2023124746A1 (en) | Cross-subnet interaction permission control | |
CN113259453B (en) | Cross-chain interaction method and device | |
CN113067902B (en) | Block chain message transmission method and device | |
CN113923232B (en) | Information synchronization method and device for block chain subnetwork | |
CN113067897B (en) | Cross-chain interaction method and device | |
CN113098982B (en) | Block chain message transmission method and device | |
WO2023050986A1 (en) | Maintenance of network architecture information of blockchain system | |
WO2024001022A1 (en) | Cross-subnet calling | |
CN113259454B (en) | Cross-chain interaction method and device | |
CN113067838B (en) | Cross-chain interaction method and device | |
CN113259117B (en) | Method for synchronizing node information lists | |
CN114363162A (en) | Block chain log generation method and device, electronic equipment and storage medium | |
CN113259120B (en) | Method for synchronizing node information lists | |
CN113259118B (en) | Method for synchronizing node information lists | |
WO2023088135A1 (en) | Data communication method and apparatus thereof, storage medium and program product | |
CN114095507B (en) | Cross-chain interaction method and block chain system | |
CN115086338B (en) | Block chain sub-network construction method, device, electronic equipment and computer readable storage medium | |
CN113259461B (en) | Cross-chain interaction method and block chain system | |
CN113923227A (en) | Block chain message distribution method and device | |
CN116743765A (en) | Block chain system and cross-chain interaction method and device | |
CN114363349A (en) | Starting method and device of block chain subnet |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 22894672 Country of ref document: EP Kind code of ref document: A1 |
|
NENP | Non-entry into the national phase |
Ref country code: DE |