Deep dive into DxChain technology and architecture. By WorldOfCoinCraft.

in #dxchain6 years ago

Disclaimer: I am not technical specialist, this article represents my personal understanding of how DxChain works. In this review you won’t find token metrics, team overview, project rating or my personal attitude for ICO.

In this overview I will try to examine DxChain white paper, figure out how everything works and try to describe main features of project in simple and convenient manner. If you are already familiar with DxChain white paper and understood everything — you can skip this article, otherwise you can find some answers here.

Before diving into DxChain technology I think it is reasonable to have a look at main technologies on which DxChain is based — Hadoop and IPFS.

Hadoop — project of Apache Software Foundation, open source distributed set of utilities, libraries and framework for development and implementation of distributed programs that work on clusters from hundred and thousands of nodes (PCs, servers, data centers etc.). It is used to implement search and context mechanics of many heavy loaded sites, such as Yahoo and Facebook. It is designed on Java within the scope of MapReduce paradigm, according to which application is divided into big amount of similar primary elements processed on cluster nodes and then put together into final result in natural way. Hadoop development started in 2005 and by 2010 Hadoop was recognized as one of fundamental technologies of so-called “big data”.

The base Hadoop framework is composed of the following modules:

  • Hadoop Common — contains libraries and utilities needed by other Hadoop modules;
  • Hadoop Distributed File System (HDFS) — a distributed file-system that stores data on commodity machines, providing very high aggregate bandwidth across the cluster;
  • Hadoop YARN — introduced in 2012 is a platform responsible for managing
    computing resources in clusters and using them for scheduling user’s applications;
  • Hadoop MapReduce — an implementation of the MapReduce programming model for large-scale data processing.

Let’s have a closer look at MapReduce technology: MapReduce is composed of two methods: a map procedure (or method), which performs filtering and sorting (such as sorting students by first name into queues, one queue for each name), and a reduce method, which performs a summary operation (such as counting the number of students in each queue, yielding name frequencies). The “MapReduce System” (also called “infrastructure”; or “framework”) orchestrates the processing by marshalling the distributed servers, running the various tasks in parallel, managing all communications and data transfers between the various parts of the system, and providing for redundancy and fault tolerance.


Another great and innovative technology which is InterPlanetary File System. IPFS is peer-to-peer and distributed file system that can literary replace HTTP and decentralize the Internet once again. It is acknowledged that IPFS doesn’t have single point of failure. IPFS technology on blockchain is proposed by Filecoin project.

interplanetary-file-system.png
IPFS works by connecting all devices on the network to the same file structure. The file structure is a Merkle DAG (words so loved by blockchain community), which combines Merkle trees (used in blockchains to ensure immutability), and Directed Acyclic Graphs (allows users to see versions of content on IPFS).
Ok, so i think these technologies have many common with blockchain and can show pretty good synergy. Now we can get back to DxChain.

DxChain Architecture

To achieve its goals DxChain is made of three different chains with their own consensus protocols. Side chains use the same token from the master chain or each can define its own secondary token with the network-defined rate. Side chains communicate with the master chain through the smart contracts of DxChain Network. Besides, side chains can interoperate each other through the chains-on-chain microservices, which includes the data and messages.

innovation.jpg
Master chain — main chain with Ethereum-compatible data structure and PoW. Computation or storage tasks as well as results are being initiated and received in master chain.

Ok, that was easy part, now to more complicated…

Data Side Chain (DSC) — the data and files uploaded into DxChain are broken down into many small pieces and then stored into the peer-to-peer storage network, such as the InterPlanetary File System (IPFS). The Data Side Chain itself works as an incentive layer; it is not being used for data storage but for upload and download of files, verifying and storing meta-information and hash for each small piece.
The main job for the “miner” in the DSC is to provide the fundamental data storage and data transfer across the P2P network. The data writer-miner will store the data in the network and the data reader-miner will retrieve the data.

Untitled-1.jpg
Proof of Spacetime (PoSt) (DSC consensus protocol) is used as the consensus method in DSC. PoSt evolved from many of its predecessors, for example Provable Data Possession (PDP), which was introduced for allowing a client that has stored data on an untrusted server to verify that the server stored the original data without retrieving it. While PDP is a perfect fit for cloud computing storage, it has several limitations for a decentralized network, such as privately verifiable computing. The Proof of Spacetime (PoSt) scheme is designed to be an improvement over the PDP scheme and to fit a decentralized environment. To ensure security of information, privacy and public verification Data Side Chain can use technology of Zero Knowledge Proofs and encryption on different stages of information upload.

Computing Side Chain — (CSC) has a similar structure as the DSC — it is hash-linked and contains the header, transaction sets, contracts of the DxChain Network and data allocation. The transactions also use the Merkle Tree structure.

Untitled-3.jpg
A client sends a computation request to the network and this request propagates through the network. Each miner uses the CSC to obtain tasks. When a task finishes, the working miner sends the confirmation to the CSC to update the task status and obtain incentives.
Any computation miner who is interested in working on the task could potentially take the task. The “miners” (solvers and verifiers) in the CSC will load the code and data into the DxChain Virtual Machine (DVM) and execute the code inside the DVM including parallel computation and verification tasks.
CSC utilizes two consensus protocols for the different types of computation, two different philosophies to design the validation process:

Verification game (CSC consensus protocol) — in theory, verification game provides a framework which enables smart contracts with no need for trust to securely perform any computation task. Moreover, when compared with the computations in traditional Ethereum smart contracts, verification game vastly reduces the number of redundant network node computations.
In a verification game, there are several “miners” roles with different functions in the system. The core roles are Solver, Challenger and Judges. A Solver is a miner who offers a solution to a given task and a Challenger is one who disagrees with the solution from the Solver.
As far as i understood (since this part of WP kind of complicated, or badlytranslated from Chinese) — Judges make some small parts of computation to check Solvers and Challengers results in number of verification rounds. Since Judges do small amount of computation they validate their results between each-other through common Nakamoto consensus (PoW).
Verification game does not trust or rely on the reputation of its participants or any trusted party in the system. A deposit is needed to perform a task from both the Solver and the Challenger. For any faulty players, they will lose the deposit. This penalty mechanism will potentially eliminate the untrusted players with the passing of time.

Provable Data Computation (CSC consensus protocol) — in Provable Data Computation DxChain team proposes a statistical way to prove the correctness of computation. First of all they determine number of identical answers they want to get, to be sure that computation is right. In WP example they propose 7 identical answers.

Untitled-2.jpg
This table should have been longer. We only see here 5 out of 7 identical results (3).
So, when a computational task is broadcasted through the network all nodes start to make computations and giving their results. Then we compare results and when we see first 7 identical answers — we choose it as right result of computation. In this case we can only get wrong answer if all of 7 nodes are adversary.

Both verification game and PDC have advantages and disadvantages. Verification game has a strong statement. However, it is an interactive verification process and the computation break-down is not easy to implement. PDC has a weak conclusion but it is enough for most distributed computing. PDC is very easy to apply to distributed computing. DxChain Network uses both verification game and PDC for the different
scenarios.

Hadoop tool sets in DxChain Network

And finaly i would like to cover some of the Hadoop tool sets in DxChain Network. The DxChain team intends to develop DPig, DHive and DMahout tools from Hadoop at this moment to facilitate the computation running on DxChain Network. And more projects will potentially be coming.

  • Pig provides a set of high-level language for expressing data analysis. Pig supports database operations and analysis for non-structured data. If the data is stored as a plain text, Pig is a perfect tool to parse and analyze it on the fly.
  • Hive facilitates reading, writing and managing large datasets residing in
    distributed storage using SQL. DxChain Network supports database schema and SQL is used to do business intelligence related operations.
  • Mahout is a framework to run machine learning algorithm including
    Canopy Clustering and Principal Component Analysis, etc.

So basicly that is it. I hope i managed to cover all the main aspects of DxChain blockchains and consensus protocols. If you have any questions I would love to discuss in Telegram.

And don’t forget to visit my Twitter with some crazy WoW/Hearthstone/Crypro related stuff — https://twitter.com/coin_craft

P.S. My referral link — https://t.me/DxChainBot?start=89exgd-89exgd

More info at https://www.dxchain.com/

Sort:  

Nice read. I leave an upvote for this article thumbsup

Have a nice day.

If you have time, I want you to watch the Webtoons drawn by me as a Korean. I want you to support my dream.

https://steemit.com/steem/@nalumsiss/it-is-thriller-webcomic-set-in-gamcheon-culture-village-in-korea

Uncomplicated article. I learned a lot of interesting and cognitive. I'm screwed up with you, I'll be glad to reciprocal subscription))

Congratulations @worldofcoincraft! You have completed the following achievement on Steemit and have been rewarded with new badge(s) :

Award for the number of upvotes received

Click on the badge to view your Board of Honor.
If you no longer want to receive notifications, reply to this comment with the word STOP

To support your work, I also upvoted your post!

Do you like SteemitBoard's project? Then Vote for its witness and get one more award!

Congratulations @worldofcoincraft! You have completed the following achievement on Steemit and have been rewarded with new badge(s) :

Award for the number of upvotes received

Click on the badge to view your Board of Honor.
If you no longer want to receive notifications, reply to this comment with the word STOP

Do you like SteemitBoard's project? Then Vote for its witness and get one more award!

Congratulations @worldofcoincraft! You have completed the following achievement on the Steem blockchain and have been rewarded with new badge(s) :

Award for the number of upvotes

Click on the badge to view your Board of Honor.
If you no longer want to receive notifications, reply to this comment with the word STOP

Do not miss the last post from @steemitboard:

SteemitBoard knock out by hardfork

Support SteemitBoard's project! Vote for its witness and get one more award!