Code Monkey home page Code Monkey logo

mangata-node's Introduction

Mangata brand

Mangata Node

Application-specific blockchain for decentralized exchange, a parachain in Polkadot ecosystem. Implementation includes MEV solution, Proof of Liquidity and no gas economy.

Themis

Issues Pull Request GitHub last commit Build Status Language

Description

Reliable decentralized exchange (DEX) blockchain - interoperable with other blockchains using Polkadot. The exchange is using a consensus algorithm that solves MEV/frontrunning problems and makes all participants' access to trading opportunities equal.

The design of the blockchain guarantees fixed-fees that provides greater control of trading costs and higher arbitrage opportunity. Assets on the exchange will serve multiple purposes- at the first iteration, they are the block producer’s stake and exchange liquidity at the same time, and more comes later.

Local Development

Follow these steps to prepare a local Substrate development environment 🛠️

Simple Setup

Install all the required dependencies with a single command (be patient, this can take up to 30 minutes).

curl https://getsubstrate.io -sSf | bash -s -- --fast

Manual Setup

Find manual setup instructions at the Substrate Developer Hub.

Build

Local target

Recommended rustc version for the build is nightly-2021-10-19

Environment variables for ethereum apps should be set up before the build:

ETH_APP_ID=0xdd514baa317bf095ddba2c0a847765feb389c6a0
ERC20_APP_ID=0x00e392c04743359e39f00cd268a5390d27ef6b44

build node:

rustup target add wasm32-unknown-unknown
cargo build --release

Docker container

./scripts/build-mangata-node-docker-image.sh

Run

Single Node Development Chain

Purge any existing dev chain state:

./target/release/mangata-node purge-chain --dev

Start a dev chain:

./target/release/mangata-node --dev

Two-Nodes Dockerized Testnet

cd ./devops
docker-compose up

Two-Nodes Multi-Validator Dockerized Testnet

sh scripts/build-multi-validator-mangata-node-docker-image.sh
docker-compose  -f devops/multi-validator-docker-compose.yml up

Debug Single Node

VS code

Export RUSTFLAGS

export RUSTFLAGS="-g"

Build node:

cargo build --release

Run node:

RUSTFLAGS="-g" cargo run -j12 --release -- --tmp --dev

Go to VS code and attach the process!

Mangata Substrate Cumulus Parachain

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.