A Short Introduction to Ontology’s Multichain Design

The Ontology Team
OntologyNetwork
Published in
6 min readJul 29, 2019

Read the full Ontology Multichain design paper on GitHub

Foreword

As a distributed ledger technology, blockchain can be used in various sectors, such as finance, health care, supply chain, and asset management. However, limited throughput and scalability, and network isolation prevent blockchain projects from better serving business applications. Among these limitations, network isolation hinders the collaboration between different blockchains and significantly limits what blockchain can do.

Introduction

Cross-chain technology is the key to realizing cross-chain collaboration and the Internet of value. Simply put, cross-chain technology is a protocol that allows two blockchains to communicate with each other. Ontology’s cross-chain solution has already been released on its TestNet. This article will briefly explain Ontology’s multichain design.

But before that, let’s take a look at some of the other projects in the market.

Plasma: This much-discussed off-chain scaling solution on Ethereum achieves scalability by moving transactions off of the main chain to less congested side chains. Instead of modifying the underlying blockchain protocol, the solution moves most of the computation off-chain and submits the results to the main chain regularly or when necessary to ensure finality.

Cosmos: Cosmos is a heterogeneous network that supports cross-chain interaction proposed by the Tendermint team. The first blockchain in the network is Cosmos Hub, which is the Cosmos MainNet, and the other parallel chains are called Zones, which achieve cross-chain operation with Hubs through the Inter-Blockchain (IBC) Protocol. In the IBC Protocol design, before the two chains connect to each other, they need to register with each other, and save each other’s validator set and Merkle Proof, so that the receiving chain can validate the message is correct. In the meantime, different Hubs can also interact with Zones through Hub routers.

Polkadot: Polkadot is a scalable heterogeneous multichain system proposed by Ethereum’s core developer Gavin Wood. It is designed to address the issue of blockchain scalability. Polkadot sees other blockchains as parallel chains and it can transfer tokens from original chains to multi-signature addresses for a temporary lock-up period, which seems to be controlled by multi-signature through relay chain technology. The result of the transaction on the relay chain will be voted by these signees to determine whether it is valid. It also introduces phishers to report and monitor transactions. Cross-chain communication can be achieved by linking Polkadot to Bitcoin, Ethereum, etc.

Ontology’s Cross-Chain Design

To improve the interoperability between blockchains and their value exchange, Ontology has proposed a lightweight, low-coupling, safe, and reliable multichain system and cross-chain solution. The solution uses the Ontology blockchain as the main chain, and supports both homogeneous side-chains and heterogeneous side-chains, and allows interaction between the main chain and side-chains, and also between side-chains. When blockchains of different structures need to interact, dApps can realize this by invoking the cross-chain management contract.

Figure: Ontology Cross-chain System

The Ontology chain network supports interaction between the main chain and side-chains, and also between side-chains. Its cross-chain design mainly includes the following parts:

Multichain Management Contract

It is responsible for registering and managing side-chains, including the registration of side-chains, state management of side-chains, and management of side-chains’ ONG staking, fund pool, and change of validator information. The contract is deployed on the main chain.

When side-chains register with the main chain, they need to submit some basic information, such as genesis block header and consensus switch epoch to the main chain. At the same time, the side-chain needs to initialize the current key block header information in its own block header synchronization contract. In addition, the side-chain needs to stake a certain amount of ONG onto the main chain to prevent malicious acts (not required for trusted side-chains).

After registration, an ONGx fund pool will be assigned to the side-chain. Each asset transfer to the side-chain will reduce the size of the fund pool and vice versa.

If the side-chain needs to exit, it needs to submit an exit application to the main chain and there will be a challenge period, during which users can convert their ONGx on the side-chain back to ONG. If they failed to convert back, they can submit the evidence to prove the malicious acts of the side-chain. After the challenge period, the side-chain can exit and redeem the stake.

Block Header Synchronization Contract

During the process of interaction between the main chain and side-chains, and between side-chains, key block header information must be synced to validate cross-chain transactions. When side-chains interact with each other, they obtain information about the previous key block header that requires cross-chain communication from the main chain. The block header synchronization contract is deployed on the main chain and each side-chain.

Cross-Chain Management Contract

All cross-chain transactions are managed by the Cross-Chain Management Contract on the source chain. To realize cross-chain interaction, dApp developers only need to follow the instructions of the Cross-Chain Management Contract. The Cross-Chain Management Contract is deployed on the main chain and each side-chain.

ONG (x) Contract

The asset contract allows the cross-chain transfer of assets, which can be used as transaction fees and mining fees for cross-chain transactions. The ONG contract on the main chain supports locking and unlocking cross-chain assets, and ONGx contract on sidechains can increase and burn cross-chain assets. The ONG contract is deployed on the main chain and ONGx contract on each side-chain.

dApp Contract

Any dApp contract developed and deployed by Ontology developers can realize normal business logic and invoke the cross-chain method in the cross-chain management contract to achieve cross-chain interaction. It is the on-chain part of the cross-chain dApp ecosystem.

Relayer

A state information synchronizer that constantly monitors requests from the cross-chain contract and some key block headers, and syncs cross-chain transactions or key block headers to earn mining fees.

Afterword

In this article, we briefly introduced the main components of the Ontology multichain design. We will share more details in future tech point articles.

The Ontology cross-chain TestNet was launched in May. We have also prepared detailed Developer Manual and video tutorials for fellow developers. Try the TestNet and see what you can do with it.

Ontology Multichain Documentation Link:

Ontology Multichain Developer Manual

Cross-Chain Tutorial

Video Tutorials Link:

Ontology Multichain TestNet

Ontology Cross-chain Contract Development

About the Ontology Research Institute

Ontology set up the research institute in order to focus more on the research and development of core blockchain technology and strengthen the ability to explore, reflect on, and apply emerging technologies, as well as make contributions to the entire industry. At present, there are more than 10 R&D personnel in the Ontology Research Institute.

Are you a developer? Make sure you have joined our tech community on Discord. Also, take a look at the Developer Center on our website, there you can find developer tools, documentation, and more.

--

--