Detailed Description
The following description of the technical solutions in the embodiments of the present application will be made clearly and completely with reference to the accompanying drawings in the embodiments of the present application, and it is apparent that the described embodiments are only some embodiments of the present application, not all embodiments. All other embodiments, which can be made by one of ordinary skill in the art without undue burden from the present disclosure, are within the scope of the present disclosure.
The inventors of the present application have long studied to find that: with the development of the blockchain, the circulated resources on the blockchain tend to be dispersed to the participants of each blockchain, so that the resources of the blockchain management mechanism for maintaining the blockchain system are less and less, which is not beneficial to the development of the blockchain system; for other participants, the acquired resources cannot generate new value, so that the enthusiasm of the participants for participating in the blockchain related transactions is reduced, and the activity of resource circulation in the blockchain system is further reduced, and the stable operation of the blockchain is affected.
Referring to fig. 1, fig. 1 is a schematic structural diagram of an embodiment of a resource management system of the present application. The resource management system 100 of the present embodiment includes a plurality of blockchain nodes 110 in a blockchain system. Blockchain nodes 110 may participate in the blockchain billing service, together maintaining a blockchain distributed ledger.
One or more management nodes 111 may also be included in the blockchain node 110. The management node 111 may manage the resources of the blockchain system. The resources of the blockchain system may include software resources, data resources, goods, services, other valuable resources, etc. of the blockchain, while the data resources may include digital currency or other digital currencies of the blockchain, etc. The management node 111 may perform management operations such as provisioning or receiving on the resources of the blockchain system.
The resource management of the blockchain system is performed, for example, by a common resource pool configured on the blockchain, and resources in the common resource pool can be used for the management of the blockchain. The management node 111 may implement resource management of the blockchain system through a common resource repository.
For example, the management node 111 may receive resources of the public node 120 and place the resources into a public repository. Management node 111 may also administer blockchains using resources in a common resource pool. The management node 111 may be a specific node in the blockchain system, such as an originating node, some nodes selected in the blockchain system that are stable in operation and high in credibility, or nodes operated by a governance agency of the blockchain system, etc. Multiple management nodes 111 may collectively manage the resources of the blockchain system. Alternatively, multiple management nodes 111 may each manage a different type of resource in the blockchain system.
The resource management system 100 of the present embodiment further includes a public node 120. Public node 120 may include nodes other than blockchain management node 111, such as other blockchain nodes 110, blockchain light nodes, or other network nodes in a blockchain system. The definition of public node 120 in this application is to be distinguished from a traditional private node. Any blockchain node 110 that can achieve the purposes of the present application, circulate resources in the blockchain, and ensure that the blockchain system does not crash or stop due to exhaustion of resources, and can interact with the outside in an open manner, may be referred to as a public node 120 in the present application. Public node 120 may communicate with management node 111, initiate resource provisioning requests to management node 111, and provision corresponding resources to management node 111 for use. The public node 120 may also obtain the corresponding credentials issued by the management node 111 after providing the resources to the management node 111, and may obtain a certain feedback when the resources are reclaimed.
Public node 120 may also be used to enable user interaction with a blockchain network. For example, the public node 120 may include a terminal device, such as a computer, a mobile phone, a tablet computer, etc., and may receive an instruction for providing resources input by a user, and send a corresponding resource providing request to the management node 111; credentials provided by the resources issued by the management node 111 may also be received and presented to the user.
In this embodiment, after the public node 120 sends a resource providing request to the management node 111, the management node 111 may generate a contract corresponding to the resource providing request by using an intelligent contract of a blockchain, and execute the contract to automatically issue a corresponding resource providing certificate to the public node 120 after receiving the resource of the public node 120. The management node 111 may also utilize the resources provided by the public node 120 to govern the blockchain, as specified by the contract, thereby maintaining healthy and stable development of the blockchain. The management node 111 performs corresponding operations through intelligent contracts, so that human intervention can be reduced, and the credibility is improved.
In this embodiment, the resource management system 100 may further include a resource information platform 130. The resource information platform 130 may include clients, websites, etc., and the resource information platform 130 may be used to manage information related to resource requirements or supplies, etc., and provide corresponding information query services. For example, the management node 111 may issue resource staging information through the resource information platform 130, and the public node 120 may query the resource information platform 130 for resource staging information.
The resource information platform 130 may be configured in a blockchain system, and may collect resource setup information issued by the management node 111 in the blockchain system, and provide an effective information query channel for the public node 120, so that the resource setup information may be quickly and effectively disclosed, and information privacy security in the blockchain system may be effectively protected. Alternatively, the resource information platform 130 may be a public information platform, and may collect resource setup information of multiple blockchain systems, and provide corresponding information query channels or unified information query channels respectively, so as to facilitate the public node 120 to obtain more comprehensive information when participating in resource setup of multiple parties, and facilitate each blockchain system to seek more resource provision.
The management node 111 of this embodiment can manage the resources of the blockchain system, receive the resources of the public node 120 through the public resource library, can obtain more resource accumulation for the blockchain system in this way, the management node 111 can use the resources accumulated to administer the blockchain, the public node 120 can also obtain corresponding feedback through providing the resources, make the resources in the blockchain system circulate and flow, the blockchain system will not collapse because of the resource is exhausted, can also produce the new value constantly, help to promote the health, stability, sustainable development of the blockchain; and the management node 111 performs resource management through intelligent contracts, so that human intervention can be reduced, and the reliability of resource management is improved.
Referring to fig. 2, fig. 2 is a flowchart illustrating a first embodiment of a blockchain-based resource management method according to the present application. The embodiment comprises the following steps:
s101: the management node receives a resource providing request of the public node.
In this embodiment, the management node may receive a resource providing request from a public node. When determining to provide the resource to the management node, the public node can initiate a corresponding resource providing request, for example, the public node directly sends the resource providing request to the management node; alternatively, the public node may send a resource provisioning request to the nearby blockchain node, which is forwarded by the blockchain node to the management node.
The resource provisioning request may be for requesting the management node to receive a first resource from the public node for use. The first resource may include a software resource, a data resource, a good, a service, other valuable resource, etc., while the data resource may include digital currency of the present blockchain or other digital currency, etc. The first resources may include one or more types of resources. The public node may initiate a resource provisioning request for one or more types of resources. The resource providing request includes, for example, identity information of the public node, related information of the provided resource, and the like. When receiving the resource providing request, the management node can determine whether to receive the resource provided by the public node according to the corresponding resource requirement.
In this embodiment, the resource management request may also be used to define rules for the management node to return the first resource and/or the second resource to the public node. After receiving the resources provided by the public node, the management platform can return the first resources to the public node according to the corresponding resource return rule, and can also return the second resources to the public node. The second resource may include a software resource, a data resource, a good, a service, other valuable resource, etc., while the data resource may include digital currency of the present blockchain or other digital currency, etc. The resource types of the second resource and the first resource may be the same or different. The second resource can be used as a public node to provide feedback of the first resource and is used for exciting the public node to participate in providing enthusiasm of the resource, thereby being beneficial to realizing rapid accumulation of the resource.
Rules for the management node to return the first resource and/or the second resource to the public node include, for example, relevant rules such as return time, return address, return mode, etc. For example, in the resource management request, the time that the management node returns the first resource and the second resource to the public node respectively may be defined as a preset time after the management node receives the first resource, the return addresses of the first resource and the second resource are the resource library addresses corresponding to the public node, the return mode is fractional return, and the like. The rules by which the management node returns the first resource and the second resource to the public node may be the same, e.g., the management node may be defined in the resource management request to return the first resource and the second resource simultaneously. Optionally, the rules of the management node returning the first resource and the second resource to the public node may be different, and the management node may return the first resource or the second resource to the public node according to the corresponding return rules, respectively.
Optionally, the resource provisioning request may further include post-breach processing rules. For example, the resource providing request may specify a processing rule or the like when the management node does not return the first resource or the second resource according to the return time or the return manner.
S102: the management node calls the intelligent contract to generate a contract corresponding to the resource providing request.
After receiving the resource providing request of the public node, the management node can call the intelligent contract of the blockchain to generate a corresponding contract. In this embodiment, the management node is deployed with a blockchain smart contract that can be used to normalize rules for the receipt or supply of resources. The management node generates a contract corresponding to the resource providing request by calling the smart contract, and the contract may be used to normalize rules of receipt or provision of resources provided by the public node.
In this embodiment, the contract may further include a rule that the management node returns the first resource and/or the second resource to the public node. For example, the management node may extract information about rules for the management node to return the first resource and/or the second resource to the public node defined in the resource providing request, and write the information into the contract, so that the management node may automatically return the first resource and/or the second resource to the public node by executing the contract according to the corresponding return rules in the contract. The management node performs resource management by utilizing the intelligent contract of the blockchain, so that the credibility of the resource management can be effectively improved, and the resource safety of the public node is protected.
Optionally, after receiving the resource providing request, the management node may further determine whether the resource providing request meets a corresponding resource requirement, and call the intelligent contract to generate a contract corresponding to the resource providing request when determining that the resource providing request meets the corresponding resource requirement.
For example, the management node can judge whether the identity of the public node is legal or not, and generate a corresponding contract when judging that the identity of the public node is legal, so that the situation that the resource raising efficiency is low due to the fact that the malicious resource providing request occupies the management node can be effectively reduced. The management node can also judge whether the type of the resources, the number of the resources, the time of the resource provision and the like provided by the public node meet the corresponding resource requirements, accept the resource provision of the public node when judging that the resource requirements are met, and generate corresponding contracts. The management node is beneficial to rapidly and accurately raising the required resources by judging and screening the resource providing request in advance.
S103: the public node transfers the first resource to a public resource pool.
In this embodiment, a common resource pool may be used to manage resource provisioning or reception for the blockchain system. After initiating the resource providing request, the public node may transfer the corresponding first resource to a public resource pool of the blockchain. Alternatively, the public node may transfer the first resource to the public resource repository upon sending a resource provisioning request. Alternatively, the public node may transfer the first resource to the public resource pool within a preset time after sending the resource provisioning request. Alternatively, the public node may transfer the first resource to the public resource pool after receiving the message that the management node confirms acceptance of the resource provision.
The management node may receive the first resource transferred from the public node to the public resource library, and may also use the resource in the public resource library. The management node may also issue corresponding credentials to the public node after receiving the first resource transferred by the public node to the public resource repository. In some embodiments, the managing node receiving the first resource transferred by the public node into the public resource repository may further comprise: judging whether the public resource library receives the first resource of the public node or not in a preset time after receiving the resource providing request; if the first resource is received, step S104 may be performed; if the first resource is not received, a contract may be executed to terminate the resource provisioning of the public node.
For example, the management node may start timing after receiving the resource providing request of the public node, and determine whether the public node transfers the corresponding first resource to the public resource library in a preset time later, so as to determine the authenticity of the resource provided by the public node. Optionally, if the management node determines that the public resource pool does not receive the first resource of the public node within the preset time, the management node may execute the contract to end the resource providing. Alternatively, rules for handling violations may be specified in the contract. If the management node judges that the public resource library does not receive the first resource within the preset time, the management node can execute the contract to carry out treatment according to the corresponding processing rule.
In some embodiments, the contract may further include resource providing rules of public nodes, for example, including a resource type, a providing time limit corresponding to different types of resources, a number of resources, a manner of providing the resources, and the like. For example, the contract may specify that the received resource type is digital currency of the blockchain, limit the resource providing time limit to five days after receiving the resource providing request, and the resource providing mode is one-time providing or multiple-time providing. Where the resources provided by the public node include a plurality of different types of resources, the contract may also separately define each type of resource providing rule, including but not limited to, a time limit for providing, a number of resources, a manner in which the resources are provided, and the like.
S104: the management node executes a contract to generate credentials provided by the first resource.
The management node, upon receiving a first resource transferred by the public node to the public repository, may execute a contract to generate a first resource provisioning credential. The credentials may serve as a basis and proof of the public node to provide the first resource to the management node. The credentials are generated by the management node based on the relevant information such as the type, the number, the time of provision, etc. of the first resource, and may store a provision record of the first resource. The vouchers may also be digital resources like bonds, which may be used to redeem other resources for corresponding value.
Optionally, the management node may further configure identification information provided by the first resource, where the identification information is stored in association with a provided record of the first resource. The management node may also generate a corresponding credential based on the identity of the public node, the identification information provided by the first resource. Thus, the privacy information security of the first resource provided by the public node can be effectively protected.
The management node may also issue credentials to the public node after generating the credentials provided by the first resource. For example, the contract may also define the format of the certificate, the generation condition, the issuing time, the issuing mode, and other relevant rules. After receiving the first resource transferred to the public resource library by the public node, the management node can execute contract judgment, generate a certificate provided by the first resource in a corresponding format when the corresponding generation condition is met, and issue the certificate provided by the first resource to the public node at effective issuing time. The public node can confirm the validity of the first resource provision after receiving the credentials.
In this embodiment, after initiating the resource providing request, the public node may further transfer the first resource to the public resource library multiple times. The management node can execute contracts to generate corresponding part of resource providing certificates after each time the public node transfers part of resources to the public resource library, so that timeliness of each resource provided by the public node to acquire the corresponding certificate can be effectively ensured, and the security provided by each resource of the public node is protected.
In some embodiments, when the management node generates the credential provided by the first resource, an operation rule corresponding to the credential may also be configured. For example, the management node may configure the effective redemption time of the credentials, whether they may be transferred, the manner in which they are transferred or destroyed, and so on. The management node can also use the intelligent contract to write the relevant operation rules of the certificate into the contract, and the validity of the certificate or the validity of the operation of the public node on the certificate is judged by executing the contract, so that the security and the credibility of the certificate are improved. Optionally, the management node may also sign the credential issued to the public node to identify the source of the credential and increase the trustworthiness of the credential.
In this embodiment, the operations related to the receipt and supply of the resources in the blockchain system, the generation, the release, the transfer or the destruction of the certificates and the like are all saved in the blockchain distributed account book, so that the operation records of the resources or the certificates are actively and seekable, and the reliability of the resource management is effectively improved.
S105: the management node uses at least a portion of the first resource for harnessing the blockchain.
In this embodiment, the management node may use resources in the common resource pool, such as using at least a portion of the first resource in the common resource pool for harnessing the blockchain. For example, the management node may use at least a portion of the first resource for maintenance of the blockchain network, maintenance and update of node devices in the blockchain system, or rewards for blockchain points to participate in blockchain transactions, etc.
The management node can utilize corresponding resources to treat the blockchain according to the requirements of the blockchain system so as to maintain the healthy and stable development of the blockchain. Alternatively, the management node may also use the first resource in the common resource pool by executing the smart contract. For example, the management node generates a contract corresponding to the resource providing request, which may also be used to normalize the usage rules of the first resource. The usage rule of the first resource includes, for example, an applicable object, a usage time, a usage amount, and the like of the first resource. When the first resource includes multiple types of resources, the contract may further include a usage rule corresponding to each type of resource. The usage rule of the first resource may be formulated by the management node according to the requirement of the blockchain system, and written into the contract after being confirmed by the public node. The management node pays out the first resource by executing the contract, so that the fairness and reliability of resource asset pays out can be ensured, and the possibility that the first resource is maliciously used is reduced.
Optionally, the management node using at least a portion of the first resource for harnessing the blockchain may further include: the management node judges whether the use of the first resource meets the use rule; executing a contract to withdraw at least a portion of the first resource from the common resource pool for governance of the blockchain if the usage rules are satisfied; if the usage rule is not satisfied, no operation is performed to withdraw at least part of the first resource from the common resource pool.
The usage rule of the first resource may include one or more rules of applying an object, a usage time, a usage number, and the like, and the management node may determine validity of the usage of the resource by making a judgment of a corresponding item when the first resource is fetched. For example, in one particular embodiment, the first resource is a quantity of digital currency, and the contract specifies that half of the first resource is to be used for maintenance of the blockchain network; when the management node extracts the first resource from the public resource library, whether the use of the first resource is correct or not can be judged in advance, and whether the number of the extracted first resource exceeds the number specified by the contract or not; if the management node judges that the resource usage is correct and the resource usage is not hyperbranched, the first resource can be extracted from the public resource library for use; if one of the items is determined to be inconsistent, e.g., incorrect usage or excessive quantity, the first resource may be relinquished. The management platform can prevent the first resource from being used in disorder and improve the security of the resource in the public resource library by judging whether the use of the first resource meets the use rule specified by the contract.
The management node of the embodiment can receive the first resource of the public node through the public resource library, so that more resource accumulation can be obtained for the block chain system; the management node uses at least part of the first resources for managing the blockchain, and the public node can obtain corresponding second resources as feedback by providing the first resources, so that the resources in the blockchain system circularly flow, the blockchain system cannot collapse due to resource exhaustion, new values can be continuously generated, and the healthy, stable and sustainable development of the blockchain can be promoted; and the management node performs resource management through the intelligent contract, so that human intervention can be reduced, and the credibility of the resource management is improved.
In this embodiment, the order of steps S101 to S105 is the description order in this embodiment, and is not limited to the order in the execution process of the resource management method based on the blockchain in this embodiment, and on the premise that the method can be implemented, some steps may be replaced with one of the order, executed simultaneously, or executed separately.
Referring to fig. 3, fig. 3 is a flowchart illustrating a second embodiment of a blockchain-based resource management method of the present application. The present embodiment is further described based on the first embodiment of the blockchain-based resource management method of the present application, and the same steps as those of the first embodiment of the blockchain-based resource management method of the present application are not described herein again. The embodiment comprises the following steps:
s201: the management node issues resource raising information on the resource information platform.
In this embodiment, the resource management system further includes a resource information platform. The resource information platform can be used for collecting resource raising information and displaying the resource raising information. The management node may also issue resource-raised information via the resource-information platform before receiving the resource-providing request of the public node. The management node issues the resource raising information, can inform other public nodes of corresponding resource demands, is beneficial to the management node to seek more resource provision, and improves the resource raising efficiency.
The resource raising information includes, for example, information about the type of resources, the number of resources, the resource receiving address, the resource raising time, the resource returning rule, the credential issuing rule, and the like of the raised resources required by the management node. When the resource is in multiple types, the resource information can also include the number of each type of resource, the receiving address and other related information. The resource staging time is, for example, the effective time for the management node to receive the resources provided by the public node, and during the staging time, the management node may receive the resources of the public node. The resource return rule includes, for example, a type of a returned resource, a time, a relevant specification of other resources as feedback, and the like after the management node receives the resource provision. The credential issuance rules include, for example, relevant specifications such as issuance time, issuance style, operability, etc.
Optionally, the management node may also send a resource-raising message to a blockchain node in the blockchain network, where the blockchain node may also serve as a public node to provide resources to the management node to assist the management node in resource-raising.
S202: and the public node inquires the resource raising information through the resource information platform.
In this embodiment, the resource information platform may further provide an information query channel, and after the management node issues the resource raising information on the resource information platform, the public node may query the resource raising information through the query channel of the resource information platform. The public node can acquire relevant information such as corresponding resource types, resource quantity, resource receiving addresses, resource raising time, resource returning rules, credential issuing rules and the like by inquiring the resource raising information.
In some embodiments, the resource information platform may also be a common information platform, and may receive resource elevation information sent by management nodes of multiple blockchain systems. The resource information platform can also be configured with corresponding numbers of the resource raising information, so that the orderly management of the resource raising information of multiple parties is facilitated. The public node can inquire a plurality of resource raising information on the resource information platform and provide corresponding resources for one or more resource raising projects through screening and matching determination.
S203: the public node sends a resource providing request about the resource corresponding to the resource staging information to the management node.
In this embodiment, after querying the resource raising information on the resource information platform, the public node may send a corresponding resource providing request to the management node when determining to provide the resource to the management node. Optionally, the resource provisioning request may further include a number of the resource staging information, so that the management node may further confirm the corresponding resource staging item after receiving the resource provisioning request.
In some embodiments, after the public node queries the resource raising information, the resource providing request may also be sent to the management node through the resource information platform. For example, when the public node determines to provide the resource for the resource raising item corresponding to a certain number, the number and related information of the resource to be provided, such as a resource type, a resource number and the like, are sent to the resource information platform, and the resource information platform can generate a resource providing request of the public node based on the corresponding information after receiving the information, and send the resource providing request to the corresponding management node.
S204: the management node obtains a first parameter in the resource staging information and a second parameter in the resource provisioning request.
After receiving the resource providing request of the public node, the management node can also extract a first parameter in the resource raising information and a second parameter in the resource providing request. The first parameter in the resource raising information includes, for example, a resource type, a resource number, a resource receiving address, a resource raising time, a resource returning rule, a credential issuing rule, and other related parameters of the raised resource required by the management node. The second parameter in the resource providing request includes, for example, a resource type, a number of resources, a time of providing the resources, a resource return address, and the like of the resources to be provided by the public node.
In this embodiment, when the management node issues the resource raising information on the resource information platform, the management node may also store the first parameter in the resource raising information. When receiving a resource providing request of the public node, the management node can directly call the stored first parameter, so that operation steps can be effectively saved, and the calculation efficiency is improved. When the management node issues the resource raising information on the resource information platform, the resource raising information can be broadcasted to the block chain network for distributed storage, so that the credibility of the resource raising is effectively improved. S205: the management node invokes the smart contract to generate a contract based on the first parameter and the second parameter.
After the management node obtains the first parameter in the resource raising information and the second parameter in the resource providing request, the management node can call the intelligent contract of the blockchain, write the first parameter and the second parameter into the intelligent contract, generate the contract based on the first parameter and the second parameter, and perform distributed storage after the contract is identified in a consensus way.
Optionally, the management node may further feed back a message confirming acceptance of the resource provision of the public node to the public node after generating the contract based on the first parameter and the second parameter. Or, the management node may also feed back a message for receiving the resource provided by the public node to the resource information platform, and the resource information platform may further feed back the message to the public node and prompt the public node to provide the corresponding resource to the management node.
S206: the public node transfers the first resource to a public resource pool.
In this embodiment, after determining that the management node confirms that the resource is provided, the public node may transfer the corresponding first resource to the public resource pool in the agreed time. When the first resource includes multiple types of resources, the public node may also transfer the multiple types of first resources to the public resource pool simultaneously or sequentially.
S207: the management node executes a contract to generate credentials provided by the first resource.
In this embodiment, the management node may receive a first resource in the public resource pool transferred to the blockchain by the public node, and execute a contract to generate a corresponding credential after receiving the first resource. The management node may also issue a corresponding credential to the public node so that the public node may confirm the validity of the first resource offer after receiving the credential.
S208: the management node uses at least a portion of the first resource for harnessing the blockchain.
In this embodiment, the management node may further use at least a portion of the first resource to administer the resource information platform, so as to effectively maintain stable operation of the resource information platform, and protect security and validity of related information in the resource information platform.
In the embodiment, the management node issues the resource raising information through the resource information platform, so that the resource raising information can be quickly and effectively disclosed, more resource provision can be sought through the resource information platform, and the resource raising efficiency is improved; the management node uses at least part of the first resources for managing the blockchain, and the public node can obtain corresponding second resources as feedback by providing the first resources, so that the resources in the blockchain system circularly flow, the blockchain system cannot collapse due to resource exhaustion, new values can be continuously generated, and the healthy, stable and sustainable development of the blockchain can be promoted; and the management node performs resource management through the intelligent contract, so that human intervention can be reduced, and the credibility of the resource management is improved.
In this embodiment, the order of steps S201 to S208 is the description order in this embodiment, and is not limited to the order of the resource management method based on the blockchain in the execution process in this embodiment, and on the premise that the method can be implemented, some steps may be replaced with one of the steps, executed simultaneously, or executed separately.
Referring to fig. 4, fig. 4 is a flowchart illustrating a third embodiment of a blockchain-based resource management method of the present application. The present embodiment is further described based on the first embodiment of the blockchain-based resource management method of the present application, and the same steps as those of the third embodiment of the blockchain-based resource management method of the present application are not described herein again. The embodiment comprises the following steps:
s301: the management node receives a resource providing request of the public node.
S302: the management node calls the intelligent contract to generate a contract corresponding to the resource providing request.
S303: the public node transfers the first resource to a public resource pool.
In this embodiment, the blockchain system may include a plurality of common repositories, each for managing the supply or receipt of a different type of resource, respectively. The public node provides the first resource for the management node, and the first resource is saved to the corresponding public resource library, so that the management node is beneficial to orderly managing various types of resources in the blockchain system.
The management node receiving the first resource transferred by the public node to the public repository may further comprise storing the first resource in the public repository of the corresponding resource type. For example, when receiving a resource providing request of the public node, the management node may provide the public node with an address of a public resource library corresponding to the resource type, so that the public node may directly transfer the first resource to the public resource library corresponding to the type. Alternatively, the blockchain system may be provided with an intermediate repository, and the public node transfers the first resource to the intermediate repository, and then the management node transfers the first resource to the public repository of the corresponding type. The arrangement of the intermediate resource library is beneficial to improving the resource receiving efficiency when the management node is used for raising various types of resources, and is convenient for classifying and counting the raised resources.
S304: the management node executes a contract to generate credentials provided by the first resource.
S305: the management node obtains a signature of a usage operation of a first resource in the common resource pool.
In this embodiment, each public repository may also be configured with a corresponding plurality of keys, respectively. The key may be used to sign usage operations of the resources in the public repository to prove the authenticity and validity of the usage operations. The plurality of keys configured by the public resource library can be respectively stored by a plurality of management nodes, so that the security is improved.
Each common repository may be managed by a plurality of management nodes, and a plurality of keys configured by the common repository may be respectively stored by the plurality of management nodes. Each management node of the blockchain system can participate in the management of a plurality of public resource libraries, and one key corresponding to the public resource libraries is saved. The management node can sign the use operation of the resources in each public resource library by using the corresponding secret key respectively.
When the management node uses at least part of the first resource for managing the blockchain, the corresponding secret key can be utilized to sign the use operation of the first resource in the public resource library, the user of the resource can be determined through the signature, and the use of the resource can be checked. The management node can also acquire signatures of the use operation of the resources by other management nodes corresponding to the public resource library by using the corresponding keys, so that the safety of the use of the resources in the public resource library can be effectively improved, and the possibility of malicious use of the resources can be reduced.
Optionally, the use of the first resource in the public resource library may also be provided with a corresponding signature rule. For example, the use of a first resource in a public repository requires the signing of a corresponding part or all of the keys of the public repository. For example, if the public resource library i is configured with three keys, and the use of the first resource requires the signature of at least two keys, then the signatures of two keys need to be satisfied when the first resource in the public resource library ii is used.
In some embodiments, the use of resources in the common resource library may also configure corresponding signature rules according to the number of resources to be withdrawn. For example, when the number of resources required to be used by the management node is large, more keys are required to sign the use operation. For example, when the management node uses the first resources in the public resource library I, if the number of the first resources is large, the management node can sign by using all keys; if the amount of the first resource to be paid out is small, the first resource of the corresponding part can be used by signing only with two keys.
The signing rules for the usage operations of resources in the common resource library may also be normalized by the intelligent contracts of the blockchain. When the management node uses the resources in the public resource library, the management node can sign the using operation by executing the corresponding intelligent contract by utilizing the key, and when judging that the signing rule specified by the intelligent contract is met, the management node uses the corresponding resources in the public resource library. The management node automatically performs key signature through the intelligent contract and judges whether the signature meets the signature rule, so that human intervention can be reduced, and the safety of resource use in a public resource library is improved.
S306: the management node uses at least a portion of the first resource to govern the blockchain.
In this embodiment, after obtaining signatures of the plurality of management nodes for the use operation of the first resource in the public resource library by using the plurality of corresponding keys, the management node may execute the use operation of the first resource, and extract at least a portion of the first resource from the public resource library for managing the blockchain.
S307: the public node sends a resource reclamation request to the management node.
In this embodiment, the public node may further send a resource retraction request to the management node to request retraction of at least part of the first resource. The resource recovery request may include information related to identity information of the public node, a resource type, a number of resources, a resource recovery address, and the like. Alternatively, the resource retraction request may include information about the credential corresponding to the resource. The public node may reclaim part or all of the provided first resources to the management node by sending a resource reclamation request to the management node.
The public node may specifically send a corresponding resource retraction request to the management node according to a rule that the management node defined in the resource provision request returns the first resource and/or the second resource to the public node. For example, in the resource management request, the time that the management node returns the first resource and the second resource to the public node may be defined as a resource library address corresponding to the public node when the return address of the first resource and the second resource is within a preset time after the management node receives the first resource. The public node may send a resource retraction request to the management node within a preset time to request retraction of a part or all of the first resources and a corresponding part or all of the second resources.
S308: the management node performs a contract transfer of at least a portion of the first resource and at least a portion of the second resource to the public node and reclaims or destroys at least a portion of the credentials.
When receiving the resource recovery request of the public node, the management node can transfer the corresponding first resource and second resource to the public node. The management node may transfer the corresponding first resource and second resource to the public node according to the resource type, the number of resources, the resource recycling address, and the like in the resource recycling request. Or, the management node may also transfer the corresponding first resource and the second resource to the public node according to the related information in the resource providing record of the public node stored in the blockchain distributed ledger.
The transfer of the first resource and the second resource by the management node to the public node may be a transfer of the corresponding resources from a common resource pool to the public node. Or, the management node can transfer corresponding resources from its own resource library or other resource libraries of the blockchain to the public node, which is beneficial to improving the flexibility of resource transfer.
In this embodiment, when receiving the resource retraction request, the management node confirms that the resource retraction request is correct, and satisfies the triggering rule of the contract, the contract may be executed, and the corresponding first resource and second resource are transferred to the public node. For example, the management node may query the issuing record of the credential in the blockchain distributed ledger, determine a contract corresponding to the first resource that needs to be retracted by the public node, and execute the contract to transfer the corresponding first resource and second resource to the public node.
When the management node transfers at least part of the first resource and at least part of the second resource to the public node, the certificate corresponding to the first resource transferred to the public node can be recovered or destroyed. When the management node returns the first resource to the public node, the corresponding certificate is withdrawn or destroyed, so that the peer-to-peer property of the certificate held by the public node and the rest of the resources to be returned can be ensured. For example, if the resource reclamation request requires that half of the first resource be reclaimed, the management node may transfer half of the first resource from the public resource pool to the public node, and reclaim or destroy the credentials corresponding to the portion of the resource. The management node can also automatically withdraw or destroy the certificates of the public nodes by executing contracts, so that the resource loss of both parties caused by omission, error withdrawal or destruction and the like can be effectively reduced.
In some embodiments, the management node may also return at least a portion of the first resource and at least a portion of the second resource to the public node and reclaim or destroy at least a portion of the credentials according to preset return rules specified in the contract. The preset return rules include, for example, related rules such as resource return time, return address, return mode, and processing mode of the credential. And the management node can execute contracts to return corresponding part or all of the first resources and the second resources to the public node at the preset resource return time. The management node automatically executes the operation of returning the resource through the contract, so that the operation steps of returning the resource can be effectively saved, and the safety and reliability of returning the resource can be improved.
The embodiment is beneficial to orderly management of the plurality of types of raised resources by the management node by arranging a plurality of public resource libraries; when the management node uses the resources in the public resource library, the management node signs the use operation of the resources by using the secret key corresponding to the public resource library, so that the safety of the resources in the public resource library can be effectively improved; the management node can also return the second resource to the public node as feedback of the first resource provided by the public node, so that the enthusiasm of the public node for providing the first resource is improved, and further, the management node is beneficial to raising more resources for managing the blockchain and maintaining the health, stability and sustainable development of the blockchain.
In this embodiment, the order of steps S301 to S308 is the description order in this embodiment, and is not limited to the order of the resource management method based on blockchain in the execution process in this embodiment, and on the premise that the method can be implemented, some steps may be replaced with one of the order, executed simultaneously, or executed separately. This embodiment may be combined with the second embodiment of the blockchain-based resource management method of the present application.
Referring to fig. 5, fig. 5 is a flowchart illustrating a third embodiment of a blockchain-based resource management method of the present application. The embodiment takes a management node as an execution main body, and includes:
S401: the management node receives a resource providing request of the public node.
In this embodiment, the resource providing request may be used to request the management node to receive the first resource from the public node for use, and define a rule that the management node returns the first resource and/or the second resource to the public node.
S402: the intelligent contract that invokes the blockchain generates the contract to which the resource provisioning request corresponds.
The contract includes at least rules for the management node to return the first resource and/or the second resource to the public node.
S403: a first resource in a common resource pool transferred by a public node to a blockchain is received.
The common resource pool may be used to manage resource provisioning or reception for the blockchain system.
S404: a contract is executed to generate credentials provided by the first resource.
S405: at least a portion of the first resource is used to govern the blockchain.
For further functions and execution steps of the management node in this embodiment, reference may be made to the descriptions of the first to third embodiments of the blockchain-based resource management method in this application, and the description is omitted here.
Referring to fig. 6, fig. 6 is a schematic structural diagram of an embodiment of an electronic device of the present application. The electronic device 60 of the present embodiment includes a processor 61, a memory 62 and a communication circuit 63, and the processor 61 is coupled to the memory 62 and the communication circuit 63.
In the present embodiment, the communication circuit 63 is used for the electronic device 60 to communicate with an external device. The memory 62 is used to store program instructions. The processor 61 is configured to execute program instructions to implement the steps of managing nodes in the blockchain-based resource management method of the present application.
In the present embodiment, the processor 61 may also be referred to as a CPU (Central Processing Unit ). The processor 61 may be an integrated circuit chip with signal processing capabilities. Processor 61 may also be a general purpose processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA) or other programmable logic device, discrete gate or transistor logic, discrete hardware components. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
For more execution procedures and functions of the electronic device 60 in this embodiment, reference may be made to the descriptions of the first to fourth embodiments of the blockchain-based resource management method in this application, and the description thereof will not be repeated here.
Referring to fig. 7, fig. 7 is a schematic structural diagram of an embodiment of a storage medium of the present application. The storage medium 70 in this embodiment is for storing program instructions 71. Program instructions 71 are capable of being executed by a processor to implement the steps of managing nodes in the first through fourth embodiments of the blockchain-based resource management method of the present application described above. For specific reference, the description of the first to fourth embodiments of the blockchain-based resource management method in the present application may be omitted herein.
The methods according to the first to fourth embodiments of the blockchain-based resource management methods of the present application may be stored in a computer-readable storage medium if implemented in the form of software functional units and sold or used as independent products. Based on such understanding, the technical solution of the present application may be embodied essentially or in part or all of the technical solution contributing to the prior art or in the form of a software product stored in a storage medium, including several instructions to cause a computer device (which may be a personal computer, a server, or a network device, etc.) or a processor (processor) to perform all or part of the steps of the methods of the embodiments of the present invention. And the aforementioned storage medium 70 includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a magnetic disk or an optical disk, or other devices including a mobile terminal or the like that can store program codes.
The foregoing description is only of embodiments of the present application, and is not intended to limit the scope of the patent application, and all equivalent structures or equivalent processes using the descriptions and the contents of the present application or other related technical fields are included in the scope of the patent application.