Resource

In Rayls, a "Resource" is a contract whose bytecode is registered on the Private Network Hub, which makes it available for deployment across every institution connected to the Private Network. Registering it once removes the need to deploy the contract manually on each ledger, and it removes the need to track contract addresses on every destination.

The Essence of Resource

A Resource represents a smart contract, and it is what allows cross-chain communication to work within the Rayls ecosystem. By registering a contract's bytecode on the Private Network Hub, Rayls allows every Rayls Sovereign ledger to deploy that contract on its own, with no manual step. An ERC20 token contract registered as a Resource on the Private Network Hub can therefore be transferred into a Rayls Sovereign ledger even where it has never been implemented on the destination ledger, because the Relayer and the Endpoint handle the contract's deployment before the token receipt is processed.

The Role of resourceId

resourceId is a unique identifier that abstracts away the complexity of different contract addresses across different blockchains. It acts as a universal reference point for the registered contract, giving consistent identification and interaction across the Rayls network.

Key Benefits

  • Simplification: Removes the work of deploying and managing smart contracts separately on each institution's ledger.
  • Uniformity: Provides a single, consistent identifier for contracts across the ecosystem, which supports both ease of use and interoperability.
  • Efficiency: Supports fast and secure cross-chain communication.

Conclusion

Resource and resourceId sit at the centre of the Rayls architecture, resolving cross-chain contract deployment and interaction in a single registration on the Private Network Hub rather than a deployment on every destination ledger.


Did this page help you?