LiquidApps - vRAM, The “Hard Drive” EOS Has Always Needed
Written by LiquidApps Team
Scalability issues have proven to be a burdensome anchor for crypto networks as they seek to sail into mass adoption. Both pure cryptocurrencies, such as Bitcoin, and smart contract platforms, like Ethereum, are slowed down by weak transaction processing capabilities as they look to expand beyond rudimentary applications. EOS was created with the primary goal of solving these problems, in an effort to become the future home of decentralized applications (dApps). Meanwhile, the EOS architecture has proven to be cheaper and quicker than competing blockchains, the prohibitive resource cost of developing and maintaining dApps are barriers to extensive dApp development and mass user adoption. For example, buying one megabyte of RAM, an EOS-specific database for storing dApp smart contracts and state information, would cost a developer approximately 65 EOS today. As it stands with the current RAM model, building sophisticated dApps that require gigabytes of storage to house relevant usage data is impractical.
The Prohibitive State of EOS RAM
The EOS Mainnet launched with 64GB of RAM, with Block Producers voting to increase the total RAM supply by 64GB a year. However, dApps that need to store user profiles and updated state information, such as current account balances, often have RAM requirements of several gigabytes. If developers need to use RAM to store comprehensive data for multiple dApps permanently, the likelihood that these applications will scale to millions of daily users is slim.
How vRAM Works
Currently, dApp developers take on two forms of RAM costs. The first is the cost of storing their dApp’s smart contract while the second is the ongoing cost of storing and updating the state of the contract. dApp state information, such as the balance for each user, is stored permanently in RAM regardless of whether or not that user is currently interacting with the dApp. In that sense, EOS RAM is a misleading term, functioning more like a “hard-disk” drive rather than a random-access memory device which only stores data relevant to live operations.
vRAM is an alternative storage solution for developers building EOS dApps that is RAM-compatible, decentralized, and enables storing & retrieving of potentially unlimited amounts of data, affordably and efficiently. vRAM allows dApp developers to migrate all relevant data from RAM to IPFS files hosted by DAPP Service Providers (DSPs), utilizing RAM to store in-use data exclusively. Using Hash and B+ Merkle Trees, the vRAM Library allows EOS dApp developers to work with the data structure optimized for efficient data retrieval that is already familiar to them — multi-index tables. By unpacking the scarce RAM database, vRAM dramatically increases the resources available for dApp developers looking to build dApps with large data requirements.
In order to optimize for both scalability and decentralization, blockchains must be designed to store the minimum amount of information needed to verify future transaction validity. vRAM gives developers an opportunity to store their dApp data off-chain, only utilizing RAM resources in order to cache in-use data and cryptographic proofs of the latest version of the file. Erected atop the EOS foundation, vRAM can become the critical backbone of dApps, housing all their relevant information including their business logic and user profiles.
Next Stop: Scalable dApps
Until now, RAM on EOS has served both the function of traditional RAM and the role played by permanent storage devices, such as a hard-drive. vRAM decouples these two components, allowing EOS RAM to operate as a random-access memory device while storing permanent data with their chosen DAPP Service Providers. An explosion in the available memory supply will potentially reduce the cost of designing an application for wide-scale adoption. With development costs decreased, teams can now build applications with true end-user utility, such as decentralized ride-sharing sites, social media platforms, and role-player games.
The possibilities with vRAM are limitless.