Original article: "The mainnet is about to go live, how to introduce Sui Network to your friends?"
On April 15, exchanges such as OKX, Bybit, and Kucoin announced that they would list Sui Token, and all related exchanges have launched a subscription mechanism for Sui Token's WL whitelist. The Sui Network mainnet launch is a step further, but there are few detailed explanations of what Sui is and how it works. This article comes from ALEX MAC'EVOY, a core team member of the Sui ecosystem, and is compiled by Sui World. The Sui ecosystem is one of the partners of Move Accelerator. (Related reading: "Sui's benchmark against Aptos has risen at least 10 times? A quick look at how to participate in token sales?")
First, we need to understand "blockchain". Another definition of blockchain is a distributed database or ledger. The closest analogy is cloud services. There are several industry giants such as Google, Amazon and Microsoft, which provide data storage and computing power to millions of projects and companies around the world. The cloud is essentially an aggregation of servers that share resources to act as a single platform.
However, relying on centralized cloud services implies some limitations:
1) The server used can be shut down by the platform;
2) Privacy is sacrificed.
Blockchain can remove the above limitations and provide decentralized services. In short, no one person or company controls the blockchain network and data. The blockchain is maintained by all the machines or servers connected to it. As long as a small number of these servers are still connected and running, the network cannot be shut down. On Sui, we call these servers "validators" because they verify transactions on the blockchain.
Sui is a layer 1 blockchain, which means it is a base-level blockchain whose software runs on a set of independently maintained "validators". In contrast, layer 2 or higher-level blockchains are complementary to layer 1 blockchains. Layer 2 blockchains may be built on top of layer 1 to increase scalability or add features that do not exist in the original chain.
This diagram of the Sui network architecture shows how applications send transactions to validators for verification.
Next, let's explain the concept of "proof-of-stake". The validators supporting the blockchain must agree on which transactions are valid, a process called consensus. When one company runs all the servers, consensus is not a problem, but when there are many independent operators, there must be a mechanism for them to agree on when to approve a transaction. The "proof-of-stake" mechanism is essentially a certificate for these independent operators to prove that they have the authority to approve transactions.
Independent operators who run “validators” that support the Sui blockchain should also be rewarded for their efforts, as running servers costs money. Sui rewards these validator operators through the chain’s native token, SUI.
Sui can also be thought of as an operating system similar to Linux, Windows, and macOS. Builders can write applications that run on these operating systems. On Sui, builders use a relatively new programming language called Move. Specifically, Sui uses a variant we call Sui Move, which is completely different from other general-purpose programming languages for blockchains such as Rust and Solidity.
Sui Capys is a game released on Sui Devnet, and each Capy exists as an object on the Sui network.
Transactions involving shared objects must be approved by validators on the blockchain, which is a resource-intensive process. On most blockchains, all objects are shared, so every transaction must go through this approval process, resulting in increased time and economic costs. Many transactions on Sui involve simple one-to-one exchanges, which reduces resource costs.
To get more technical, each Sui object must have the following fields:
Unique ID: Similar to a hash or contract ID on Ethereum;
Version: Displays the transaction number of the object, starting from 1;
Transaction summary: indicates the last transaction that contains this object as an output;
Owner field: displays the owner, which can be an account address, another object, immutable or shared
Of course, builders can customize objects by including additional fields, and Sui allows for a lot of creativity in object design.
As a popular use case, builders can create a game that is composed of objects. For example, in a racing game, the player's car is an object that the player owns, and the car in the game can be modified, so the player can add a paint job, change the tires, upgrade the supercharger, etc. to make the car more competitive. Each of these upgrades is a separate object that is owned by the car object in Sui as the player obtains and adds to the car.
We mentioned shared and owned objects above, let’s take a deeper look at how Sui processes transactions using these different types of objects. We mentioned consensus when referring to the validators that Sui uses to verify transactions. Sui only needs to reach consensus on shared objects. Normal transactions involving owned objects do not require consensus.
Owned objects are not included in "blocks" of the blockchain; they interact directly with validators on Sui using a simplified algorithm. Due to this architecture, owned object transactions occur almost instantly. In fact, these simple transactions may involve one player giving a car to another player in a racing game, someone posting a message to a social network, or submitting a vote in a poll.
Sui's novel consensus mechanism can execute both simple and complex transactions, with the former requiring fewer resources and processing very quickly
How does Sui verify simple transactions?
1) The sender broadcasts the transaction to all Sui validators;
2) Each Sui validator will vote on the transaction, and each vote has a weight based on the validator’s stake;
3) The sender collects the Byzantine-resistant majority votes into a certificate and broadcasts it back to all Sui validators, which processes the transaction, records it on Sui, and ensures that the transaction cannot be deleted or revoked.
For more complex transactions, Sui performs verification in the following steps:
1) The sender broadcasts the transaction to all Sui validators;
2) Each Sui validator will vote on the transaction, and each vote has a weight based on the validator's stake.
3) The sender collects the Byzantine-resistant majority votes into a certificate and broadcasts it back to all Sui validators. However, this time, the certificates are ordered through a process called Byzantine agreement, in which validators must reach consensus, and once the transaction is successfully ordered, the sender broadcasts the certificate to the validators to settle the transaction.
As mentioned above, single transactions bypass consensus and are processed almost instantly. Transactions using shared objects must go through consensus. If Sui processes many transactions simultaneously using shared objects, each consensus must occur sequentially, which could delay transactions. Most other blockchains only allow the latter transaction type and do not allow for bypassing consensus.
Sui's distributed computing model is more like a traditional cloud service than a typical blockchain. Many blockchains use a token economics model to control server load: as load increases, gas fees also increase. Higher gas fees reduce the number of transactions because users can only pay a specific amount.
As the load on Sui increases, validators can simply add more processing power, similar to how Amazon Web Services might add more servers as client traffic increases. Validators can earn more gas fees instead of spending more, so they are incentivized to add validation servers. This model not only allows Sui to scale to support increased user traffic, but also maintains a smooth and stable gas fee, allowing more users to join the Sui ecosystem. Increasing network capacity in this way ensures that games run quickly, apps can respond quickly, and social applications are released, builders will not set fees due to rising gas prices, and the network will not fail due to gas wars.
Sui Move is the native programming language of Sui. The core Move language on which Sui Move is based was created in 2018 and is specifically designed for smart contract programming developed on the blockchain. The creators of Move saw the need for abstractions for assets and access control that did not exist in previous blockchain programming languages. These abstractions make sense for blockchains because decentralization puts assets and access control at the center of most activities on the network.
However, as the founding team of Sui began developing this new blockchain, they saw the need to further improve Move. Although Move was designed for smart contract programming on the blockchain, it still lacked native support for blockchain-specific concepts such as accounts, transactions, time, and cryptography. Blockchains need to build support for these features, which is not only time-consuming but also leads to inconsistent implementation of key features such as security. Sui Move aims to integrate everything blockchain developers need to create high-performance, secure, and feature-rich applications.