close

In this article, we will look at what applications are being developed using smart contracts, what are the current challenges and our view on the future of smart Contracts.

First, let’s understand the role of smart contract. Smart contract defines and executes transactions in the form of a software code. It comprises of operations that act on the state of the blockchain ledger. So, the current capability is to manipulate and view the state in the blockchain and ensure that the shared ledger stays consistent across all the nodes in the network. 

If we decide to extend the behavior of smart contract beyond just manipulating and retrieving the ledger state, like interacting with external systems for data or a third-party service, then these new requirements or extensions can impose challenges that need to be addressed. To understand this in detail, let’s take an example of a DApp, where there is a requirement to read data from a public website (say stock price or forecast) as part of the smart contract functionality. Even if the data may not change in the future, how can one verify and confirm that the data received is same, genuine and unaltered throughout the network. In such a scenario, we would need a third-party system, which provides a transaction proof of the data that was accessed and retrieved at that moment. This third-party system providing secured transactions and value is referred to as oracle in blockchain terminology. So instead of smart contract accessing the public feed, the oracles extract the information and push the data into the smart contract.

Let’s take another example of an existing business network or multiple networks, already having its own set of enterprise data maintained in a data store like relational databases or some legacy systems. How it can leverage blockchain technology for trust, visibility and speedy settlement and how smart contract can play a role here? Do we end up replacing legacy systems to make it work with the blockchain network or do we find out a way to achieve consensus on the existing enterprise data without replacing old systems?

To understand this, let’s take an example of a trade finance application where multiple entities like banks (consortium of importer and exporter banks), shipment and logistic firms, custom/port authorities, buyers and sellers – all maintaining their own respective systems. They are looking to form a consortium of a trade finance network with the objective to devise a common smart contract that can be made accessible and visible to all the entities along with enforcing trust and speedy settlement.

In order to realize this use case, each system would need to provide their respective data in the form of attributes (we will refer to this as shared business attributes) which is essential for trade to happen. Think of shared business attributes as a common schema definition for a trade, where each entity owns and provides their respective data and make updates to it. The smart contract would then be bootstrapped with shared business attributes from each system. Each entity based on where they are in the trade process, would make necessary state changes to the smart contract and update the ledger and their respective backend systems. For example, once the goods are delivered, the shipment vendor would need to update their backend system, say a SAP application (for their actual processing and reporting). In order for the external application to receive data or attributes value via smart contract, it needs to listen to the events generated from the blockchain network (say order received event) and accordingly make updates to their backend system.

So, in a nutshell, the current generation of smart contracts and its use cases would be around providing shared business attributes that will be visible to all the concerned entities, while the rest of the functionality would still happen in their respective systems (like SAP, CRM or Mainframe system).  The smart contracts of today would need to work in tandem with external systems, be it a SAP or a bank legacy application and not to replace existing systems.

In the future as blockchain platforms and smart contract technology evolves, we envision a seamless integration between smart contracts and the external systems. Most importantly the application integration should not break the consensus and therefore there is a need to create a secured environment (using crypto materials) that can seamlessly communicate with external systems. We will refer to this as an ‘external contract container’ responsible for integrating with the outside world. As we dwell deeper into this integration scenario, it might also make sense that the ‘external contract container’ should not run on all the nodes. For example, the shipment entity or node updating its SAP system need to happen only once and not by all the nodes (other participants of the blockchain network). So we are looking at only certain nodes, which are authorized based on their roles, running the ‘external contract container’ to communicate with external systems. We provided only one integration scenario, but there would be many such integrations patterns emerging in the future.

As you see the function of smart contract will evolve in future to cater to many such requirements, we are probably looking at the first generations of blockchain smart contract technology. We also envision new blockchain platforms with new consensus algorithms addressing external application integration using smart contract technologies and many more innovations in this space that will enable the business and consumer networks perform business with trust and transparency as part of next generation internet applications.

To conclude this section, the golden rule for any blockchain transaction is that it should be deterministic in nature. Using smart contracts allows us to manipulate the state in the blockchain in a consistent way. This is ideal for any use cases, which require shared visibility and trust across parties, where collaboration happens through an automated workflow and updates to the blockchain state is handled by smart contracts.

Learn how to build Blockchain applications with my free course – https://www.udemy.com/course/building-blockchain-applications-using-ethereum-hyperledger-fabric/

Tags : blockchain-guide
Navveen

The author Navveen