Skip to content

Latest commit

 

History

History
106 lines (63 loc) · 4.6 KB

dapps.asciidoc

File metadata and controls

106 lines (63 loc) · 4.6 KB

Decentralized Applications (Dapps)

What is a Dapp?

Dapp stands for Decentralized Application. Unlike a traditional Application, a Dapp does not belong only to one single provider or server, but the whole stack would be deployed and operated in a distributed fashion on a peer-to-peer network.

A typical Decentralized application stack would consist of Front-end, Back-end and Data Storage. There are many advantages to creating a decentralized application that a typical centralized architecture could not provide:

1) Resiliency: Having the business logic written on a smart contract means that a Dapp backend will be fully distributed and managed on the Blockchain. Unlike deploying an application on a centralized server, a dApp will have no downtime and will continue to persist as long as the Blockchain is still operating.

2) Transparency: The open source nature of a Dapp allows anybody to fork the code and have the same application running on the Blockchain. On the same note, any interaction with the Blockchain will be stored forever and anyone with a copy of the Blockchain can gain access to it.

3) Censorship Resistance: As long as a user has access to an Ethereum node, he/she will always be able to interact with a Dapp without interference from a centralized control. No service provider or even the owner of the smart contract could alter the code once it is deployed on the network.

Components of a Dapp

Blockchain (Smart Contracts)

Front End (Web UI)

Data Storage

On Chain vs. Off Chain data

IPFS

Swarm

Swarm developer’s onboarding guide; https://github.com/ethersphere/swarm/wiki/swarm

Similarities/differences between Ethereum’s Swarm and IPFS; https://github.com/ethersphere/go-ethereum/wiki/IPFS-&-SWARM

Centralized dB

Dapp Frameworks

There are many different Development frameworks and libraries written in many languages which allows for better Developer experience in creating and deploying a DApp.

Truffle

Truffle is a popular choice and provides a manageable development environment, testing framework and asset pipeline for Ethereum.

With Truffle, you get:

  • Built-in smart contract compilation, linking, deployment and binary management.

  • Automated contract testing with Mocha and Chai.

  • Configurable build pipeline with support for custom build processes.

  • Scriptable deployment & migrations framework.

  • Network management for deploying to many public & private networks.

  • Interactive console for direct contract communication.

  • Instant rebuilding of assets during development.

  • External script runner that executes scripts within a Truffle environment.

Getting Started & Documentation; http://truffleframework.com/docs

Embark

The Embark Framework focuses on serverless Decentralized Applications using Ethereum, IPFS and other platforms. Embark currently integrates with EVM blockchains (Ethereum), Decentralized Storages (IPFS), and Decentralized communication platforms (Whisper and Orbit).

With Embark you can:

  • Blockchain (Ethereum)

    • Automatically deploy contracts and make them available in your JS code. Embark watches for changes, and if you update a contract, Embark will automatically redeploy the contracts (if needed) and the dapp.

    • Contracts are available in JS with Promises.

    • Do Test Driven Development with Contracts using Javascript.

    • Keep track of deployed contracts; deploy only when truly needed.

    • Manage different chains (e.g testnet, private net, livenet)

    • Easily manage complex systems of interdependent contracts.

  • Decentralized Storage (IPFS)

    • Easily Store & Retrieve Data on the DApp through EmbarkJS. Including uploading and retrieving files.

    • Deploy the full application to IPFS or Swarm.

  • Decentralized Communication (Whisper, Orbit)

    • Easily send/receive messages through channels in P2P through Whisper or Orbit.

  • Web Technologies

    • Integrate with any web technology including React, Foundation, etc..

    • Use any build pipeline or tool you wish, including grunt, gulp and webpack.

Getting Started & Documentation; https://embark.readthedocs.io

Dapple

Populous