DEV Community

Cover image for Ethereum versus Daml, an analysis of Enterprise Blockchain

Posted on

Ethereum versus Daml, an analysis of Enterprise Blockchain

This post was originally created on Daml Blog by Shaul Kfir.

As developers identify the blockchain infrastructure and application development platform to support their applications, many community members seek to understand the differences between Daml and Ethereum. Both Daml and Ethereum are used as blockchain open source to create applications that solve industry-level problems; however, there are several differences between the two platforms with Ethereum being a public blockchain network and Daml on the other hand supporting permissioned multi-party projects.

Image description

When to use Ethereum over Daml

  • You need a public mainnet and do not need privacy - No public mainnet supports Daml, yet. So it makes sense to use Daml if you’re a company starting a network or joining an existing network, but not if you’re an independent developer who wants to deploy something to an existing ecosystem. You also benefit from the amount of innovation happening on public blockchain, which is inevitably faster due to more participation.

  • You need a trustless DAO - Daml does not support DAOs natively, yet. However, you can build them (though it is hard). Every contract in Daml has a set of owners (called “signatories” in Daml) who can upgrade the contract. An Ethereum DAO can never be changed, so it’s fully trustless once deployed (but it can also have bugs that you can’t fix).

When to use Daml over Ethereum:

  1. *You need privacy for anything more than tokens *- Daml has privacy as a built-in concept. That means that every node in Daml sees a subset of the smart contracts on the network. ZKP may be able to do this in the future, but there are no current ZKP frameworks that get anywhere near Daml’s expressivity. As opposed to public blockchains, private institutions like banks, insurance companies, and many supply chain industries realized that the concept of collective data storage and management by a distributed ledger (DLT) could be very useful as an industry collaboration tool. Indeed, private networks can maintain transaction confidentiality of participants, terms, and data at scale.
  2. You need flexibility - Daml runs on many different blockchains (Hyperledger Fabric, Besu, Corda, VMware, and Daml Hub). From the Smart Contract structure perspective, users of a Daml-based solution can engage with the solution provider either through traditional means (standard messaging protocols, for example) or by operating their own participant node in a DLT network.
  3. You need interoperability - Unlike Ethereum, which usually displays a single, unified view of their network’s stored ledger, Daml implementations are multi-channels. Daml smart contracts can compose over multiple networks simultaneously, so your smart contract can call out to Daml smart contracts on other networks, and help increase data coordination across shared ledgers.
  4. You are writing complex logic - Daml’s developer productivity is much higher than Solidity. You declare the high-level logic of your contract, and the compiler and runtime take care of the rest. There is less room to make security mistakes in Daml and much better tooling. Learn more about Daml ledger basics.

Next let's take a closer look at how privacy is guaranteed in Daml:

Daml Fine-grained privacy

Daml pushes the state-of-the-art in privacy preservation to a whole new level by also being able to determine the need to know at a very fine-grained level. With Daml, transactions can be broken up into sub-transactions, and these sub-transactions then selectively revealed to participants. Returning to our DvP example, when written in Daml, the DA Platform would reveal the entire transaction only to Alice and Bob. The bank and the CSD would be notified that the cash and shares, respectively, got transferred, and they can verify that the transfers were correct. But they would not learn anything about why the transfers happened. We can visualize this below, where each box shows to whom the part of the transaction is shown:

Image description
To conclude, both Daml and Ethereum are helpful blockchain open source to solve unique problems experienced by individuals and businesses. However, if your project demands a higher level of security, flexibility and interoperability, Daml offers the facility to maintain the privacy of an organization’s information and improves the effectiveness of deployment. It is unclear how the technology will pan out in the medium-to-long run, but it seems inevitable that the smart contracts technology will revolutionize the financial system, replace legacy systems, and make the industry more efficient.

Watch Daml Training Videos Here.

Discussion (0)