The invention relates to a cross-chain
relay platform-based cross-chain method and
system. The cross-chain method includes the following steps that: step 1, a user request is sent to a
service contract; step 2, whether a cross-chain transaction occurs is determined; if a cross-chain transaction occurs, the method enters a step 3, if no cross-chain transactions occur, the method enters a step 6; step 3, a cross-chain contract is called, an event is generated, and parameters are transferred to a cross-link
relay platform; step 4, an event notification transferred from a
blockchain is received, and the cross-chain contract of an another chain is called, and the cross-chain contract is adopted to call the
service contract, so that the transaction can be completed; step 5, the transaction savesan execution state, if the on-chain transaction of two transaction parties is successful, the state is updated, and if the execution of one party fails, the transaction is rolled back; and step 6, the method enters a
blockchain network platform. With the method and
system of the invention adopted, different data types can be well unified; and the same method is adopted to call different
blockchain platforms, the inconsistence of the interfaces and parameters of different chains can be ignored; and message transmission between the different blockchains can be realized.