Scaling ERC-721: The New Extension – Sean

In early 2018, ERC-721 was officially created in GitHub. ERC stands for Ethereum Request for Comment and 721 is the issue number created in GitHub where the initial conversation of the standard took place. If you’d like to learn about this process you can go here.

ERC-721 was the first standard interface for defining digital goods on Ethereum. For non-technical people, ERC-721 offers a universal method to build smart contracts that track ownership of of digital goods, coined non-fungible tokens (NFTs). This standard provides a common method for decentralized platforms to display, manage, and track information relating to these NFTs.

The ERC-721 standard opened up standard opened up an entirely new class of assets, ownership, and marketplaces much of which is still largely untapped, but is already proving to be popular. In one recent seven-day period, the top ten apps listed on NonFungibles.com have brought in more than $790,000. The Sandbox, a community-driven platform where creators can monetize digital assets and gaming experiences, brought in 800 ETH (about $228k)in the first hour of their digital land pre-sale.

As the ERC-721 market continues to grow so does the need for the ability to scale the smart contracts. Users need to be able to do things like mint a massive amount of tokens at one time, transfer a massive amount of tokens, and be able to track ownership of all these assets. We need to do this in a way that is cost effective and doesn’t fail under the confines of the Ethereum blockchain. As millions of tokens are minted we need contracts with the ability to scale.

ERC-1155 was created and added as a standard in 2019 to try to solve these problems, but it falls short when it comes to minting massive amounts of tokens in a cost-effective way. With ERC-1155 it’s either going to cost hundreds (or thousands) of dollars or it’s going to run out of gas. Don’t get me wrong: ERC-1155 has it’s benefits and I believe that it has a rightful place in the Ethereum ecosystem. But it would be foolish to disregard ERC-721 in favor for ERC-1155.

It’s important to get the community on board when proposing something like ERC-1155 and ERC-721 and the approach Enjin (the company behind ERC-1155) took was to say that ERC-721 was the old and ERC-1155 was the new. The implied message was ERC-721 was a dusty old standard in need of replacement. ERC-721 is a powerful standard and can support minting billions of tokens in a cost effective way by using ERC-2039, the Consecutive Transfer Extension.

I’d like to introduce to you ERC-2309, an extension to ERC-721, which provides a standardized method to track the creation and transfer of an infinite amount on ERC-721 NFTs. With this simple extension, the ERC-721 mass minting and transfer scalability problem is solved.

This extension provides even more scalability of the ERC-721 specification. It is possible to create, transfer, and burn 2²⁵⁵ non-fungible tokens in one transaction. However, it is not possible to emit that many Transfer events in one transaction. The Transfer event is part of the original specification which states:

This emits when ownership of any NFT changes by any mechanism. This event emits when NFTs are created (from == 0) and destroyed (to == 0). Exception: during contract creation, any number of NFTs may be created and assigned without emitting Transfer. At the time of any transfer, the approved address for that NFT (if any) is reset to none.

This allows for the original Transfer event to be emitted for one token at a time, which in turn gives us O(n) time complexity. Minting one billion NFTs can be done in one transaction using efficient data structures, but in order to emit the Transfer event – according to the original spec – one would need a loop with one billion iterations which is bound to run out of gas, or exceed transaction timeout limits. This cannot be accomplished with the current spec. This extension solves that problem.

Many decentralized marketplaces and block explorers utilize the Transfer event as a way to determine which NFTs an address owns. The Consecutive Transfer Extension provides a standard mechanism for these platforms to use to determine ownership of many tokens.

Cargo — a platform to create, manage, and sell non-fungible tokens — is the first to support ERC-2309. I founded Cargo and launched the first version in the summer of 2019. I built Cargo so developers, entrepreneurs, and businesses could easily build products that utilize NFTs.

Here’s an example of the power of the Consecutive Transfer extension. We are helping SludgeFeed, a crypto news website, mint 400 NFTs for the 2020 NFT.NYC conference. Below is a link to the mint transaction on Etherscan which uses the Consecutive Transfer extension

ERC-2309 makes this possible. Scaling ERC-721 for enterprise use is a reality and Cargo provides this functionality out of the box with the Cargo ERC-721 contract. With Cargo ERC-721 tokens can be minted programmatically, or through the UI without the need for any coding experience. You can manage millions upon millions of NFTs at once and create custom applications using the Cargo APIs.

The Cargo V2 system has not yet launched, but if you’d like to stay up to date go to www.cargo.build

Комментарии