Choosing the best blockchain platform for your business from 4 famous open source projects
從 4 個(gè)著名的開源項(xiàng)目中為您的業(yè)務(wù)選擇最好的區(qū)塊鏈平臺
來源:Choosing the best blockchain platform for your business from 4 famous open source projects
In today’s global environment, where some countries have been forced by the current medical crisis to stop non-essential parts of their economies, the situation seems quite dire, to say the least. Hopefully, there will also be a silver lining at the end of all this, and we will all emerge stronger through our collective efforts.
在當(dāng)今的全球環(huán)境中案训,一些國家在目前的醫(yī)療危機(jī)中被迫停止其經(jīng)濟(jì)中的非必要部分山叮,這種情況似乎非常嚴(yán)峻瞧毙。 希望在這一切最終會有一線希望狼钮,通過我們共同的努力混萝,所有人都能變得更加強(qiáng)大狱杰。
Certainly, everyone is becoming acutely aware of how fragile the world economy is, with all its global supply chains. Many elements of those chains (for example the global supply chain of essential goods) are owned by large entities, or totally centralised. For that reason, people are turning their heads (at least when speaking about IT) towards various open source projects that are promising to bring decentralisation to the supply chain and, with that, a high degree of resilience to disruptions.
當(dāng)然屹耐,每個(gè)人都已經(jīng)敏銳地意識到世界經(jīng)濟(jì)及其全球供應(yīng)鏈的脆弱性。 這些鏈的許多要素(例如臼膏,全球基本商品供應(yīng)鏈)由大型實(shí)體擁有或完全集中硼被。 因此,人們開始轉(zhuǎn)向(至少在談?wù)?IT 時(shí))轉(zhuǎn)向各種開源項(xiàng)目渗磅,這些項(xiàng)目有望將去中心化帶入供應(yīng)鏈嚷硫,并因此具有高度的抵御破壞力的能力。
Even if we ignore the current situation, staying relevant in the rapidly changing technological evolution should still be on the minds of every tech business leader out there from startups to large corporations, especially when it comes to blockchain/DLT technology. Therefore, if you are a business leader who is concerned about not losing relevancy or simply want to understand when and where different processes should be more decentralised, you will want to make an informed decision about using blockchain to benefit your business.
即使我們忽略當(dāng)前的情況始鱼,從快速發(fā)展的公司到大型公司仔掸,每個(gè)技術(shù)業(yè)務(wù)領(lǐng)導(dǎo)者都應(yīng)該緊記與快速變化的技術(shù)發(fā)展保持聯(lián)系,尤其是在涉及區(qū)塊鏈/DLT 技術(shù)時(shí)医清。 因此起暮,如果您是一位業(yè)務(wù)領(lǐng)導(dǎo)者,擔(dān)心不失去相關(guān)性状勤,或者只是想了解何時(shí)應(yīng)該在何處分散各個(gè)流程鞋怀,那么您將需要就使用區(qū)塊鏈?zhǔn)鼓臉I(yè)務(wù)受益做出明智的決定双泪。
To help with your decision regarding that, in this article we will look at 4 open source blockchain/DLT projects, starting (in no particular order) with Hyperledger Fabric, then moving on to Corda, then Quorum and finishing with Substrate.
為了幫助您做出決定持搜,在本文中密似,我們將研究 4 個(gè)開源區(qū)塊鏈/DLT 項(xiàng)目,從 Hyperledger Fabric 開始(無特定順序)葫盼,然后進(jìn)入 Corda残腌,然后是 Quorum,最后是 Substrate贫导。
The main considerations include: ease of programming (smart contracts), throughput (for example transaction throughput), app footprint (like memory footprint), scalability, data privacy (the ability to store encrypted data) and, last but not least, support (either community support or official support).
主要考慮因素包括:易于編程(智能合約)抛猫,吞吐量(例如事務(wù)吞吐量),應(yīng)用程序占用空間(如內(nèi)存占用空間)孩灯,可伸縮性闺金,數(shù)據(jù)隱私(存儲加密數(shù)據(jù)的能力),以及最后但并非最不重要的支持( 社區(qū)支持或官方支持)峰档。
1. Hyperledger Fabric (incubated by the Linux Foundation)
1. Hyperledger Fabric(由Linux基金會孵化)
The name Hyperledger refers to the overall umbrella project of open source blockchains and related tools, started in 2015 by the Linux Foundation and hosting software contributions from companies such as IBM, Intel, SAP Ariba, and others. The Hyperledger brand name has various frameworks under its umbrella that can be found here. We will focus on one such framework called Hyperledger Fabric.
Hyperledger 是指開源區(qū)塊鏈和相關(guān)工具的整體項(xiàng)目败匹,該項(xiàng)目由 Linux 基金會于 2015 年啟動巢株,并托管于 IBM鳖宾,Intel,SAP Ariba 等公司做軟件貢獻(xiàn)锻离。 Hyperledger 有廣泛的多個(gè)餓框架欢顷,可以在這里找到槽棍。 我們將專注于一種稱為 Hyperledger Fabric 的框架。
First of all, I would like to say that I see Hyperledger Fabric more like a fast DLT (Distributed Ledger Technology) platform, not a blockchain, or at least not according to my definition of a blockchain — for me a blockchain is a decentralized and immutable distributed database, where truth is determined by a consensus mechanism, like voting made by participants or PoW hashing, so that no central authority arbitrates what is true which translates into a system that deals well with faults and malicious actors. On the other hand, the standard Hyperledger Fabric architecture cares more about uptime (the transaction validation system is Crash Fault Tolerant first and foremost) and doesn’t do a great job resisting malicious actors.
首先抬驴,我想說的是炼七,我認(rèn)為 Hyperledger Fabric 更像是一種快速 DLT(分布式賬本技術(shù))平臺,而不是區(qū)塊鏈布持,或者至少不是按照我對區(qū)塊鏈的定義——對我而言特石,區(qū)塊鏈?zhǔn)侨ブ行幕模?不可變的分布式數(shù)據(jù)庫,其中的真相由共識機(jī)制確定鳖链,例如參與者的投票或 PoW 哈希姆蘸,因此沒有中心機(jī)構(gòu)可以仲裁真相,從而轉(zhuǎn)化為可以很好地處理故障和惡意行為者的系統(tǒng)芙委。 另一方面逞敷,標(biāo)準(zhǔn)的 Hyperledger Fabri c架構(gòu)更關(guān)心正常運(yùn)行時(shí)間(交易驗(yàn)證系統(tǒng)首先是 Crash Fault Tolerant),并且在抵抗惡意行為者方面做得并不出色灌侣。
Like many other commercially-focused DLTs, Fabric is a permissioned DLT.
與許多其他側(cè)重于商業(yè)的 DLT 一樣推捐,F(xiàn)abric 是一個(gè)受認(rèn)可的 DLT。
If you are wondering how hard it is to develop a brand new smart contract for Fabric, things couldn’t be more easy. With Hyperledger Fabric, it is possible to pick from a wide range of languages to develop your smart-contract (called chaincode), including: Go, Java, JavaScript and TypeScript and maybe Python as well, in the future. What this means is, if you are a developer, you can quickly start building your chaincode in one of those languages mentioned above or if you are a business/team leader, you don’t need to invest any extra money for hiring Solidity devs or for upskilling your current dev team. For that reason, in terms of ease of programming, Hyperledger Fabric is the best.
如果您想知道為 Fabric 開發(fā)全新的智能合約有多難侧啼,那再簡單不過了牛柒。 借助 Hyperledger Fabric堪簿,將來有可能從多種語言中進(jìn)行選擇來開發(fā)您的智能合約(稱為鏈碼),包括:Go皮壁,Java椭更,JavaScript 和 TypeScript,也許還有 Python蛾魄。 這意味著虑瀑,如果您是開發(fā)人員,則可以使用上述一種語言快速開始構(gòu)建您的鏈碼滴须,或者如果您是業(yè)務(wù)/團(tuán)隊(duì)負(fù)責(zé)人舌狗,則無需花費(fèi)任何額外的錢來雇用 Solidity 開發(fā)人員或提升您當(dāng)前開發(fā)團(tuán)隊(duì)的技能。 因此扔水,就易于編程而言痛侍,Hyperledger Fabric 是最好的。
That being said, it is very important to note that every smart contract lives inside its own Docker container (yes, Hyperledger uses Docker as its Virtual Machine, not the EVM or JVM or anything like that). This can be the main limiting factor of this project when it comes to app footprint, specifically memory footprint because of the large RAM overhead for each container, which limits the number of distinct contracts to just a dozen chain chaincode contracts on a normal system.
也就是說魔市,每個(gè)智能合約都生活在自己的 Docker 容器中(是的主届,Hyperledger 使用 Docker 作為其虛擬機(jī),而不是 EVM 或 JVM 或類似的東西)嘹狞,這一點(diǎn)非常重要岂膳。當(dāng)涉及到應(yīng)用程序的占用時(shí),這可能是這個(gè)項(xiàng)目的主要限制因素磅网,特別是內(nèi)存占用谈截,因?yàn)槊總€(gè)容器的大內(nèi)存開銷,這限制了不同契約的數(shù)量涧偷,在一個(gè)正常的系統(tǒng)中簸喂,只能有 12 個(gè)鏈的鏈碼合約。
There is no built-in cryptocurrency in Hyperledger to prevent spam or to overcome the halting problem of infinite loops in state changing transactions. You might ask, if for some reason the smart contract execution doesn’t terminate (becomes frozen or something similar to that), what’s preventing the entire chain from freezing? Well, if the transaction does not execute within the configured timeout (by default ten seconds) the chaincode container will be killed by Hyperledger Fabric. Just to be sure the smart contract can be killed, one can make the containers bound to just one CPU, for example, but this means the overall execution of every piece of chaincode may be slower than necessary.
Hyperledger 中沒有內(nèi)置加密貨幣來防止垃圾郵件或克服狀態(tài)變化交易中的無限循環(huán)的中止問題燎潮。您可能會問喻鳄,如果由于某些原因智能合約執(zhí)行沒有終止(變成凍結(jié)或類似的情況),是什么阻止了整個(gè)鏈的凍結(jié)确封?好吧除呵,如果事務(wù)沒有在配置的超時(shí)時(shí)間內(nèi)執(zhí)行(默認(rèn) 10 秒),鏈碼容器將被 Hyperledger Fabric 殺死爪喘。例如颜曾,為了確保智能合約可以被終止,可以將容器綁定到一個(gè) CPU 上秉剑,但這意味著每個(gè)鏈碼的整體執(zhí)行可能比必要的要慢泛豪。
Another interesting thing to note is that, unlike Ethereum or other systems, chaincode smart contracts cannot communicate with each other. This potentially limits functionality.
另一個(gè)值得注意的有趣之處是,與以太坊或其他系統(tǒng)不同,鏈碼智能合約無法相互通信诡曙。這可能會限制功能臀叙。
Hyperledger Fabric uses two types of consensus mechanism: traditional crash fault tolerant Resource Aggregation for Fault Tolerance (RAFT) protocol or a byzantine fault tolerant (BFT) consensus protocol.
Hyperledger Fabric 使用兩種類型的共識機(jī)制:傳統(tǒng)的崩潰容錯(cuò)資源聚合容錯(cuò)(RAFT)協(xié)議或拜占庭容錯(cuò)共識協(xié)議。
Looking at the first consensus option, RAFT, since this consensus mechanism is Crash Fault Tolerant, so when it comes to scalability it’s easier to scale nodes than in BFT systems meaning one can easily set up a DLT with super high transaction throughput, somewhere in the order of magnitude of thousands of transactions per second, but this can only really be done for consortium projects where all members already know and trust each other to some degree.
看第一個(gè)共識選項(xiàng)价卤,RAFT劝萤,因?yàn)檫@一共識機(jī)制崩潰容錯(cuò),所以可伸縮性時(shí)更容易比在 BFT 系統(tǒng)節(jié)點(diǎn)規(guī)模意義很容易建立一個(gè) DLT 超高事務(wù)吞吐量荠雕,在成千上萬的數(shù)量級每秒事務(wù)數(shù)稳其,但這只有在所有成員都在某種程度上了解和信任彼此的聯(lián)合體項(xiàng)目中才能真正做到驶赏。
When it comes to data privacy, everything is OK here, as Fabric offers the ability to create private data collections, which allow a defined subset of organisations on a channel the ability to endorse, commit, or query private data.
說到數(shù)據(jù)隱私炸卑,F(xiàn)abric 提供了創(chuàng)建私有數(shù)據(jù)集合的能力,這允許在通道上定義的組織子集能夠認(rèn)可煤傍、提交或查詢私有數(shù)據(jù)盖文。
Finally, last but not least, there is a lot of support, and here I am talking about community support. There is a lot of community activity that seems to happen on Stack Overflow or Reddit, however, there isn’t the same level of dev activity like in Ethereum. There are a lot of tutorials available describing how to setup your own Fabric network that either super high-level relying on basic setup scripts or really deep into the tech where the write-up assumes you are a DevOps expert especially when it comes to configuring all the crypto materials needed for a brand new network. This was once a complex process orchestrated through Hyperledger Composer in previous versions, which is no longer possible because Composer was recently deprecated. Therefore the barrier to entry is now slightly higher.
最后,最后但并非最不重要的一點(diǎn)是蚯姆,有很多支持五续,在這里我說的是社區(qū)支持。 Stack Overflow 或 Reddit 上似乎發(fā)生了很多社區(qū)活動龄恋,但是疙驾,開發(fā)活動的水平并沒有像以太坊那樣。 有很多可用的教程描述了如何建立自己的Fabric 網(wǎng)絡(luò)郭毕,這些網(wǎng)絡(luò)要么是超高級的它碎,而是依賴于基本的設(shè)置腳本,要么是深入到技術(shù)的基礎(chǔ)上(本文假設(shè)您是 DevOps 專家)显押,尤其是在配置所有對象時(shí)扳肛。 全新網(wǎng)絡(luò)所需的加密材料。 這曾經(jīng)是以前版本中通過 Hyperledger Composer 精心安排的一個(gè)復(fù)雜過程乘碑,由于最近不推薦使用 Composer挖息,因此不再可能。 因此兽肤,進(jìn)入壁壘現(xiàn)在略高套腹。
So, in conclusion, Hyperledger Fabric is perfect for when all your transaction logic can be handled by one or two smart-contracts and when you want to have low latency and a high throughput for the chain, and aren’t afraid to read through a lot of guides to get started.
所以,總之资铡,Hyperledger Fabric 非常適合當(dāng)你所有的事務(wù)邏輯由一個(gè)或兩個(gè)智能合約电禀,并且需要低延遲和高吞吐量時(shí),并不害怕閱讀大量的攻略時(shí)使用害驹。
2. Corda (by R3)
Corda is a DLT system built from scratch in Java by R3, a US company co-founded in 2015 by 40 of the world’s largest banks, but now comprising over 300 companies in their ecosystem. It is therefore understandable why the majority of current Corda-related news and developments focus on financial services applications.
Corda 是 R3 用 Java 從零開始構(gòu)建的 DLT 系統(tǒng)鞭呕,R3 是一家美國公司,2015 年由 40 家世界上最大的銀行共同創(chuàng)立,但現(xiàn)在在他們的生態(tài)系統(tǒng)中有超過 300 家公司葫松。因此瓦糕,可以理解為什么當(dāng)前大多數(shù)與 Corda 相關(guān)的新聞和發(fā)展都聚焦于金融服務(wù)應(yīng)用程序。
Unlike almost all the other blockchain clients that tend to take inspiration and even code from other projects such as Ethereum, it only has a few aspects of it that are taken from Public Blockchain software, the majority are new.
與幾乎所有其他傾向于從以太坊等項(xiàng)目中獲得靈感甚至代碼的區(qū)塊鏈客戶端不同腋么,它只有少數(shù)幾個(gè)方面來自公共區(qū)塊鏈軟件咕娄,而大多數(shù)是新的。
There are two versions: the private Corda Enterprise, which is out of scope for this article, and the open-source Corda project. The two are said by R3 to be near identical in most aspects.
Corda 有兩個(gè)版本:私有的 Corda Enterprise(不在本文討論范圍內(nèi))和開源 Corda 項(xiàng)目珊擂。R3 說這兩者在大多數(shù)方面幾乎相同圣勒。
In terms of ease of programming, as in programming smart-contracts, it is worth mentioning that if you don’t have expert-level experience in Java or if you don’t have a team of Java devs at your disposal, Corda is really not for you. Smart contracts in Corda are named CorDapps and take the form of a set of JAR files (Java archive files which act like executable Java programs) containing class definitions written in Java (or with the new libraries, in Kotlin as well).
就編程的簡便性而言,就像在編寫智能合約中一樣摧扇,值得一提的是圣贸,如果您沒有 Java 方面的專家級經(jīng)驗(yàn),或者如果您沒有可使用的 Java 開發(fā)人員團(tuán)隊(duì)扛稽,那么 Corda 確實(shí)是不適合你吁峻。 Corda 中的智能合約被稱為 CorDapps,并采取一組 JAR 文件(類似于可執(zhí)行 Java 程序的 Java 存檔文件)的形式在张,其中包含用 Java(或用 Kotlin 編寫的新庫)編寫的類定義用含。
With regards to the throughput, there is no information about a specific number of transactions per second. I can only estimate a very large number of transactions would be possible. When a user creates a transaction, this transaction will eventually go to a coordinating node called a notary node, or a notary cluster designated to prevent “double-spends”. A network can have several notary clusters, because they are all pluggable, and the interesting part is the fact each notary can implement a variety of consensus algorithms. This particular architectural decision means Corda is unlike other blockchains or DLT solutions currently available.
關(guān)于吞吐量,沒有關(guān)于每秒特定數(shù)量的事務(wù)的信息帮匾。 我只能估計(jì)可以進(jìn)行大量交易啄骇。 當(dāng)用戶創(chuàng)建交易時(shí),該交易最終將到達(dá)稱為公證節(jié)點(diǎn)的協(xié)調(diào)節(jié)點(diǎn)瘟斜,或指定為防止“雙花”的公證集群缸夹。 一個(gè)網(wǎng)絡(luò)可以有幾個(gè)公證集群,因?yàn)樗鼈兌际强刹迦氲暮咦腥さ氖敲總€(gè)公證可以實(shí)現(xiàn)多種共識算法明未。 這一特殊的架構(gòu)決策意味著 Corda 與當(dāng)前可用的其他區(qū)塊鏈或 DLT 解決方案不同。
Like in Hyperledger Fabric, you can have a consensus mechanism like RAFT or a new BFT called BFT-SMaRt. For that reason, if we were to start benchmarking a Corda network that uses RAFT, I am sure we would achieve thousands of transactions per second.
像在 Hyperledger Fabric 中一樣壹蔓,您可以具有共識機(jī)制趟妥,例如 RAFT 或稱為 BFT-SMaRt 的新 BFT。 因此佣蓉,如果我們要開始對使用 RAFT 的 Corda 網(wǎng)絡(luò)進(jìn)行基準(zhǔn)測試披摄,我相信我們每秒將實(shí)現(xiàn)數(shù)千筆交易。
Unfortunately, Corda requires a lot of tuning, because the CorDapp contract is something that depends on CPU and network management being as close to the metal as possible, which is because it is not virtualized enough. This has its good side, as it has a low memory or app footprint.
不幸的是勇凭,Corda 需要大量的調(diào)優(yōu)疚膊,因?yàn)?CorDapp 契約依賴于 CPU 和網(wǎng)絡(luò)管理,這是因?yàn)樗粔蛱摂M化虾标。這有它好的一面寓盗,因?yàn)樗休^低的內(nèi)存或應(yīng)用程序占用。
This requires a lot of work done in the deterministic JVM sandbox provided but, fortunately, in terms of support, there is a lot of community support on Stack Overflow and Slack.
需要在提供的確定性 JVM 沙箱中完成大量工作,但是幸運(yùn)的是傀蚌,就支持而言基显,在 Stack Overflow 和 Slack 上有很多社區(qū)支持。
When it comes to data privacy, this is built in. Every piece of data stored is encrypted properly, the encryption is done in such a way that only the parties included within the transaction can decrypt it. Things get a bit more complicated when there are a lot of parties that want to share only certain things, therefore the need of something called channels. Thus, if you know the channel where a chaincode made by someone else is deployed, you can make your new chaincode talk to it, but only on that particular channel. If you are calling a chaincode on a different channel, you are limited to read only.
當(dāng)涉及數(shù)據(jù)隱私時(shí)善炫,它是內(nèi)置的撩幽。對存儲的每個(gè)數(shù)據(jù)都進(jìn)行適當(dāng)?shù)募用埽用艿姆绞绞侵挥薪灰字邪母鞣讲拍軐ζ溥M(jìn)行解密箩艺。 當(dāng)有很多聚會只想共享某些東西時(shí)窜醉,事情就變得復(fù)雜了一些,因此需要一種叫做渠道的東西艺谆。 因此榨惰,如果您知道將其他人制作的鏈碼部署到的頻道,則可以使新的鏈碼與之對話擂涛,但只能在該特定頻道上進(jìn)行读串。 如果要在其他頻道上調(diào)用鏈碼聊记,則僅限只讀撒妈。
With regards to scalability, it is easy to add any number of nodes, thus the network being very easy to scale.
關(guān)于可伸縮性,添加任意數(shù)量的節(jié)點(diǎn)很容易排监,因此網(wǎng)絡(luò)擴(kuò)展非常容易狰右。
So it appears that Corda is good for fast enterprise projects where the rest of the codebase that already exists is also written in Java/Kotlin, or parties are willing to adapt to these.
因此,Corda 似乎適用于快速的企業(yè)項(xiàng)目舆床,在這些企業(yè)中棋蚌,已經(jīng)存在的其余代碼庫也是用 Java/Kotlin 編寫的,或者各方都愿意適應(yīng)這些項(xiàng)目挨队。
3. Quorum (by JP Morgan)
3. Quorum (摩根大通)
Quorum is an Ethereum-based blockchain (and here I am talking about the GoLang flavour of Ethereum), that has been developed to provide various industries with a permissioned implementation of Ethereum.
Quorum 是一個(gè)基于以太坊的區(qū)塊鏈(這里我指的是以太坊的 GoLang 版本)谷暮,它被開發(fā)用于為各個(gè)行業(yè)提供以太坊的許可實(shí)現(xiàn)。
Quorum was forked from the main Ethereum Go (Geth) repository more than two years ago by a team of developers managed by JP Morgan who at that time had experimented with another project called Juno. At the moment, it looks unclear how the future ownership of the project will evolve, because there are currently ongoing negotiations to merge Quorum with the startup ConsenSys.
Quorum 是在兩年多前由摩根大通管理的一個(gè)開發(fā)團(tuán)隊(duì)從以太坊 Go(Geth)主庫中分離出來的盛垦,當(dāng)時(shí)該團(tuán)隊(duì)正在試驗(yàn)另一個(gè)名為 Juno 的項(xiàng)目湿弦。目前,該項(xiàng)目未來的所有權(quán)將如何發(fā)展還不清楚腾夯,因?yàn)槟壳罢谶M(jìn)行合并 Quorum 和初創(chuàng)公司 ConsenSys 的談判颊埃。
Because of the amount of public information out there about Geth and Quorum, I would definitely give it a thumbs up when it comes to community support.
由于存在有關(guān) Geth 和 Quorum 的大量公共信息,因此在社區(qū)支持方面蝶俱,我肯定會表示贊許班利。
I can’t really say Quorum satisfies the ease of programming requirement because I am aware not everyone knows how to code in Solidity (Quorum is EVM based). The good news is that the tooling is comparatively excellent. That’s because Solidity is a very well documented language, and there are even plugins for VSCode and Atom.
我不能說 Quorum 滿足了便宜編程要求,因?yàn)槲抑啦⒉皇敲總€(gè)人都知道如何使用 Solidity 進(jìn)行編碼( Quorum 是基于 EVM 的)榨呆。 好消息是該工具相當(dāng)出色罗标。 這是因?yàn)?Solidity 是一種非常有據(jù)可查的語言,甚至還有 VSCode 和 Atom 的插件。
In terms of data privacy, well, it is all up to you, as smart contracts can be either public (i.e. visible and executable by all participants in the network) or private to one or more network participants.
就數(shù)據(jù)隱私而言闯割,這完全取決于你自己皿哨,因?yàn)橹悄芎霞s可以是公開的(即網(wǎng)絡(luò)中所有參與者可見和可執(zhí)行),也可以是一個(gè)或多個(gè)網(wǎng)絡(luò)參與者的私有合約纽谒。
If we compare the throughput to other Ethereum chains we can make a few simple calculations. Block size by default is 3.7G units of gas which is significantly higher than the 8M gas default on other private Ethereum solutions. The default block time is 1 second but in fact the gas limit is so high that consuming it all would take longer than the block time. Based on this, we can conclude that the actual practical limit should be at least as high as a few 1000s of transactions a minute (more extensive testing would be needed though). Similar to Fabric or Corda, there are two possible consensus mechanisms supported, RAFT (the default consensus mechanism) and Istanbul, a form of BFT. Therefore, if we go with the default option of non-BFT RAFT, the transaction throughput can be even higher.
如果我們將吞吐量與其他以太坊鏈進(jìn)行比較证膨,我們可以進(jìn)行一些簡單的計(jì)算。 默認(rèn)情況下鼓黔,區(qū)塊大小為 3.7G 單位央勒,明顯高于其他私有以太坊解決方案的 8M 單位。 默認(rèn)的阻塞時(shí)間為 1 秒澳化,但實(shí)際上限制非常高崔步,以至于消耗掉所有所花費(fèi)的時(shí)間將比阻塞時(shí)間更長。 基于此缎谷,我們可以得出結(jié)論井濒,實(shí)際的限制至少應(yīng)至少達(dá)到每分鐘幾千個(gè)事務(wù)(盡管需要進(jìn)行更廣泛的測試)。 與 Fabric 或 Corda 相似列林,支持兩種可能的共識機(jī)制瑞你,即 RAFT(默認(rèn)共識機(jī)制)和 Istanbul(一種 BFT 形式)。 因此希痴,如果我們使用非 BFT RAFT 的默認(rèn)選項(xiàng)者甲,則事務(wù)吞吐量可能會更高。
In terms of app footprint, as in mainly memory footprints, I would say that the memory consumption is quite low and one can compare it to Ethereum. Extra memory is needed though for the overhead of working with private transactions.
在應(yīng)用程序占用方面砌创,主要是內(nèi)存占用虏缸,我認(rèn)為內(nèi)存消耗相當(dāng)?shù)停梢耘c以太坊進(jìn)行比較嫩实。但是需要額外的內(nèi)存來處理私有事務(wù)刽辙。
Of course, Quorum has the unique property of high scalability because the project is based on the Geth Ethereum client, therefore any scaling solutions from Ethereum MainNet could be easily added in later.
當(dāng)然,由于項(xiàng)目基于 Geth 以太坊客戶端甲献,Quorum 具有高可擴(kuò)展性的獨(dú)特屬性宰缤,因此任何來自以太坊主網(wǎng)的可伸縮性解決方案都可以在以后很容易地添加進(jìn)去。
In conclusion, if you know Solidity or if you have at least one Solidity dev in your team, Quorum is the perfect option for you to build something quick, something that doesn’t necessarily need to be super fast.
總之竟纳,如果你了解 Solidity撵溃,或者你的團(tuán)隊(duì)中至少有一個(gè) Solidity 開發(fā)者,那么 Quorum 便是你快速創(chuàng)造內(nèi)容的最佳選擇锥累,而這些內(nèi)容并不一定需要非吃堤簦快。
4. Substrate (by Parity Tech)
Now, as the old saying goes, it is good to save the best for last, let’s look at Substrate (maybe not necessarily the best, but certainly the most intriguing one).
現(xiàn)在桶略,正如老話所說语淘,最好的留到最后诲宇,讓我們看看 Substrate(也許不一定是最好的,但肯定是最有趣的)惶翻。
Substrate, made by Parity Tech (the same company that made the Parity Eth client), is not a blockchain per se. You can think of it as being like Wordpress where you can add certain templates or build a few templates yourself and get your own website that meets all of your requirements and is different from any other website out there, but still able to interoperate with them. If you want to build a new project using Substrate, all you have to do is implement a very small number of hooks in your code and then, almost immediately, you have your custom blockchain client for your favourite OS.
Substrate 由 Parity Tech(制作 Parity 以太坊客戶端的那家公司)制造姑蓝,其本身不是區(qū)塊鏈。你可以把它想象成 Wordpress吕粗,你可以添加特定的模板纺荧,或者自己構(gòu)建一些模板,得到你自己的網(wǎng)站颅筋,滿足你所有的要求宙暇,不同于任何其他網(wǎng)站,但仍然能夠與它們進(jìn)行互操作议泵。如果您想使用 Substrate 構(gòu)建一個(gè)新項(xiàng)目占贫,您所要做的就是在代碼中實(shí)現(xiàn)非常少的鉤子,然后先口,幾乎立即型奥,您就擁有了您最喜歡的操作系統(tǒng)的定制區(qū)塊鏈客戶端。
When it comes to ease of programming (programming smart contracts, of course), I must say, it is not that easy. It looks like there are two options: first one is to use the EVM module, which is good if you know Solidity or you have a Solidity dev; and second option is to use ink! module which uses the Rust programming language but that might be even harder because it seems Rust developers are in short supply. In fact, Parity Ethereum is the world’s second largest Rust codebase in existence, explaining the team’s choice here.
說到編程的便利性(當(dāng)然是編寫智能合約)碉京,我必須說厢汹,這并不容易∈湛洌看起來有兩個(gè)選擇:第一個(gè)是使用 EVM 模塊坑匠,如果你知道 Solidity 或你有一個(gè) Solidity 開發(fā)者,這是很好的選擇卧惜;第二種選擇是使用 Ink! 使用 Rust 編程語言的模塊,但這可能更加困難夹纫,因?yàn)樗坪?Rust 開發(fā)人員供不應(yīng)求咽瓷。事實(shí)上,Parity 以太坊是世界上現(xiàn)存的第二大 Rust 代碼庫舰讹,這解釋了團(tuán)隊(duì)的選擇茅姜。
Therefore working knowledge of Rust and/or Solidity is required to be able to do any significant customization or adaptation of Substrate.
因此,需要有 Rust 和/或 Solidity 的工作知識月匣,能夠進(jìn)行任何重要的定制或適應(yīng) Substrate钻洒。
Because of how new this is, transaction throughput is unknown. My guess is that because of the fact that all smart contracts will end up compiling down to WASM (Web Assembly) if they are written in Rust and, because of how fast the underlying WASM interpreter runs, I would say that it might be at least a few times faster than Quorum as an example. Note that there are various mechanisms substrate allows you to introduce in order to limit bad user behaviour that would slow down the network (e.g. configurable transaction fees and storage fees).
由于這是新東西,事務(wù)吞吐量是未知的锄开。我的猜測是素标,因?yàn)樗兄悄芎霞s將會編譯到 WASM (Web組件)如果他們都用 Rust 編寫,因?yàn)榈讓?WASM 解釋器運(yùn)行速度萍悴,至少我會說它可能是幾倍法定人數(shù)头遭。請注意寓免,底層允許你引入各種機(jī)制來限制會減慢網(wǎng)絡(luò)速度的不良用戶行為(例如,可配置的交易費(fèi)用和存儲費(fèi)用)计维。
The fact that you get to write your own code in one of the performant programming languages out there (Rust) means a much improved app footprint.
你可以用一種性能編程語言(Rust)編寫自己的代碼袜香,這意味著應(yīng)用占用空間會得到很大改善。
In terms of scalability, I have really good news here. As substrate is a framework for building blockchains, you have a lot of potential for scaling using various mechanisms. Single Substrate blockchains can scale horizontally by joining the future Polkadot network, should they wish to. Substrate allows you to write a custom fork choice or use a “Hybrid” consensus mechanism, using the combination of the classic AURA Proof of Authority consensus from the old Parity client, the new BABE non-BFT block generator, or even a Proof-of-Work algorithm for block generation + GRANDPA for finality.
在可伸縮性方面鲫惶,我有一個(gè)好消息蜈首。由于 Substate 是構(gòu)建區(qū)塊鏈的框架,所以使用各種機(jī)制進(jìn)行擴(kuò)展有很大的潛力欠母。單個(gè) Substate 區(qū)塊鏈可以通過加入未來的 Polkadot 網(wǎng)絡(luò)進(jìn)行橫向擴(kuò)展疾就,如果他們愿意的話。Substrate 允許你編寫一個(gè)自定義的分叉選擇或使用一個(gè)“混合”共識機(jī)制艺蝴,使用來自舊 Parity 客戶端的經(jīng)典 AURA 權(quán)威證明共識猬腰,新的 BABE 非 bft 塊生成器,甚至是塊生成的工作量證明算法+最終的 GRANDPA猜敢。
In terms of scalability, as Substrate is a framework for building blockchains, you have a lot of potential for scaling using various mechanisms. Single blockchains can scale horizontally, by joining the Polkadot network should they wish to. Or you can build your own private polkadot-like ecosystem, something that will end-up looking like a blockchain of blockchains. Building parachains will also solve the problem of data privacy but you can also use Zero Knowledge Proofs with libraries made by Zkcrypto.
就可伸縮性而言姑荷,由于 Substrate 是一個(gè)構(gòu)建區(qū)塊鏈的框架,您可以使用各種機(jī)制進(jìn)行擴(kuò)展缩擂。單個(gè)區(qū)塊鏈可以通過加入 Polkadot 網(wǎng)絡(luò)進(jìn)行橫向擴(kuò)展鼠冕,如果他們愿意的話】瓒ⅲ或者懈费,你可以建立自己的私人 Polkadot 生態(tài)系統(tǒng),最終看起來像一個(gè)區(qū)塊鏈的區(qū)塊鏈博脑。構(gòu)建降落傘鏈也可以解決數(shù)據(jù)隱私問題憎乙,但你也可以使用零知識證明與 Zkcrypto 制作的庫。
Finally, in terms of support (community support mainly), it’s now easy easy to contact the Substrate team through the public Riot chat, or if not, you can find a lot of materials on Awesome Substrate or on StackOverflow.
最后叉趣,在支持方面(主要是社區(qū)支持)泞边,現(xiàn)在很容易通過公共的 Riot 聊天聯(lián)系到 Substrate 團(tuán)隊(duì),如果沒有疗杉,你可以在 Awesome Substrate 或 StackOverflow 上找到很多材料阵谚。
I am not sure if I want to recommend this solution to small businesses just yet. All I can say for sure is the fact that this is quite new and very open for experimentation. I really recommend using Substrate in your project if you feel a bit adventurous, but if you are not willing to experiment, stick with one of the other platforms presented above.
我不確定我是否要向小型企業(yè)推薦這種解決方案。我所能肯定的是烟具,這是一個(gè)相當(dāng)新的東西梢什,非常開放的實(shí)驗(yàn)。如果您覺得有點(diǎn)冒險(xiǎn)朝聋,我真的建議在您的項(xiàng)目中使用 Substrate嗡午,但是如果您不愿意嘗試,請堅(jiān)持使用上面提供的其他平臺之一玖翅。
In conclusion, when it comes to rating the best platform, I personally think we should not choose only one, as solutions should be built according to the specified business model, or the size of your organization. Perhaps, in the future, banking organisations will settle on banking-inspired Corda, B2B businesses will move to platforms that run on commercially-sponsored chains like Hyperledger Fabric or Quorum, whereas B2C businesses will move to chains like Substrate. But only time will tell.
綜上所述翼馆,在評價(jià)最佳平臺時(shí)割以,我個(gè)人認(rèn)為我們不應(yīng)該只選一個(gè),應(yīng)該根據(jù)具體的業(yè)務(wù)模式应媚,或者組織的規(guī)模來構(gòu)建解決方案严沥。也許,在未來中姜,銀行組織會選擇受銀行啟發(fā)的 Corda, B2B 企業(yè)將轉(zhuǎn)向在商業(yè)贊助鏈上運(yùn)行的平臺消玄,如Hyperledger Fabric 或 Quorum,而 B2C 企業(yè)將轉(zhuǎn)向像 Substrate 這樣的區(qū)塊鏈丢胚。但只有時(shí)間會告訴我們答案翩瓜。