Aleph.im — Solving The Challenges of Solana Indexing With Our Decentralized Indexing Technology

Edd Smith
Aleph.im
Published in
10 min readOct 3, 2022

Blockchains get their name from their data storage technique. Each blockchain immutably stores data on a distributed, decentralized ledger with blocks of data forming a long chain. Validators keep adding new blocks to the chain, with the blockchain getting longer with new transactions. But what happens, if you want to find details about a user’s transaction history? Tracing down a long chain of blocks to find the relevant data isn’t often practical.

Although distributed and decentralized blockchains make our data more secure, it also makes it harder to locate those data. Without proper tools, it is difficult to query blockchain data and make it readily available to users on request. Thus, blockchain indexing protocols have come up to index queries from the blockchain network. However, these indexing solutions have their own set of problems. Before delving into the problems, let us first understand the concept of indexers.

What are indexers?

Indexers fetch raw data from a blockchain network, and efficiently store it for easy access. These indexers are node operators that use the ETL (Extract, Transform, and Load) procedure for querying blockchain data. ETL is a data integration strategy facilitating quick data collection from different sources to consolidate into a single location. The indexers extract on-chain data, transform them into a human-readable format, and load the data into a database for user accessibility.

Indexers work via protocols that retrieve data from the blockchain to provide query processing services.

What are blockchain indexing protocols?

Blockchain indexing protocols facilitate the collection, processing, and access of relevant blockchain data that is otherwise difficult to obtain. These protocols utilize indexer nodes and APIs (Application Programming Interfaces) to provide data feeds to dApps. During high network activity, indexing protocols enable dApp developers to efficiently index and query blockchain data, offering a better experience for users.

One of the most popular blockchain networks, Solana, has long been suffering from a lack of proper blockchain indexing protocols. Solana runs on a hybrid Proof-of-Stake (PoS) and Proof-of-History (PoH) consensus mechanism. As the 9th largest cryptocurrency with a marketcap of over $12 billion, Solana registers a high network activity. However, the long absence of efficient Solana indexing protocols has affected developers and users in different ways.

Let us explore some of the issues before suggesting a solution to address them.

What are the problems with Solana indexing protocols?

Indexing the Solana blockchain is not an easy task and involves the following difficulties:

Centralized indexing

dApps often have to depend on centralized indexing solutions to retrieve on-chain data. However, relying on centralized solutions goes against the fundamental principle of trustlessness and decentralization in blockchain ecosystems. Apart from deviating from philosophical ideals, centralized indexing has pragmatic technological and economic consequences.

Centralized solutions managed by a single entity can be problematic. Your data is never truly “yours” and can be manipulated, lost or deleted. Moreover, centralization leads to a single point of failure. Any physical damage to the hardware from unintended factors like fire or natural calamities can disrupt data feeds to dApps.

High network latency

Due to inadequate technical infrastructure, a spike in data requests during high network activity clogs the network. Therefore, extraction and access of on-chain data become a time-consuming process. Users have to wait longer to get data feeds which hamper the user experience. Without any mechanism to manage and balance a spike in requests, indexing and querying blockchain data entails high latency.

However, innovative technological solutions like Aleph.im solves the aforementioned problems.

Aleph.im: The Decentralized Indexing Solution for Solana

Aleph.im is a decentralized, distributed, serverless platform that offers computation services, storage facilities, and indexing solutions. A cross-blockchain protocol with a programming language agnostic interface, Aleph.im solves the problems of centralized cloud computing platforms with its Virtual Machine technology.

In August 2021, Aleph.im launched decentralized indexing solutions for the Solana blockchain ecosystem. Since then, Aleph.im has indexed over 3000 market pairs on Solana. Aleph.im has also been handling over 14 million transaction requests per day on 220+ independently run resource nodes.

Aleph.im’s Solana indexer runs on cost-efficient Virtual Machines (VMs), which adds more flexibility and makes data retrieval easier. The indexing tools play a key role in enabling the Solana ecosystem to migrate from centralized indexing systems.

Many Solana projects index data on their own, which requires enormous computing resources and storage capacities. Thus, for practical reasons, these projects use Amazon Web Service (AWS) or Google Cloud (GC) to index data. Moreover, accessing Solana blockchain history with Solana BigTable will skyrocket their costs.

However, Aleph.im decentralizes the indexing procedure with its VMs running on 250+ independent compute resource nodes. Solana projects can now use Aleph.im’s decentralized indexing to get access to Solana’s history. Therefore, Aleph.im offers a groundbreaking technological innovation where projects can deploy decentralized indexing on Aleph.im’s network.

When Aleph.im originally launched our Solana indexer, the network was running on 50 independent nodes. Now in 2022, Aleph.im is up to 79 core channel nodes and 291 compute resource nodes, further enhancing scalability. Aleph.im’s VMs can auto-scale with a rise in demand, making data indexing services available without any latency. Users can instantly access data feeds as the indexed data remains permanently available on Aleph.im’s decentralized network.

Aleph.im is helping Solana projects achieve full-stack decentralization with its set of decentralized indexing tools. Implementing GraphQL endpoints (subgraphs), Aleph.im is making front-end data accessibility easier. However, unlike decentralized indexers like The Graph, which index the whole blockchain at once, Aleph.im first indexes fresh data. Aleph.im also offers the world’s first decentralized IPFS pinning service, enabling permanent decentralized storage of user data.

Aleph.im solves the challenges of indexing the Solana blockchain in the following ways:

  • Decentralized Function as a Service (FaaS): Aleph.im leverages micro Virtual Machines (microVMs) offering FaaS to quickly access blockchain data even during high network activity. Moreover, Aleph.im’s unique cloud and virtual decentralized load balancing infrastructure prevent network clogging.
  • Distributed Virtual Machines (VMs): Aleph.im distributes the VMs across multiple resource nodes throughout the network, avoiding any single point of failure. Thus, apart from offering better security; fire or natural calamities at server locations cannot hinder data requests on the network. In the near future, VMs can spawn additional indexer instances during a spike in network activity so that Aleph.im can auto-scale to avoid data flow bottlenecks.

How does the Aleph.im Solana indexer work?

Before getting into the working of Aleph.im’s Solana indexing solution, we have to first understand the architecture of resource nodes. The resource nodes network consists of microVMs that can work individually, in clusters, or collectively with other clusters. These mircoVMs offer a decentralized FaaS to query and index on-chain data via IPFS or other external sources. When a dApp requests data, it triggers a VM that functions through load balancers to regulate data management during high network demand.

Now that you know about the resource nodes network, let us explain Aleph.im’s indexing methodology. Indexing happens through the following steps:

  • A dApp requests data which immediately launches a Virtual Machine (VM).
  • The VM queries and indexes data from the blockchain, IPFS or other external sources. In the meantime, chain indexing keeps running in the background.
  • Aleph.im stores the indexing data on the node.
  • Aleph.im uses the GraphQL front-end so that users can easily access the data.
Aleph.im indexing architecture

With a 58% growth since January 2022, there were over 37 million active wallets on the Solana blockchain in May 2022. Consequently, Solana produces a huge amount of on-chain data. Thus, querying and indexing the Solana chain requires special strategies.

Aleph.im uses a unique dedicated indexing strategy for each Solana project. Each project has aggregated indexes that can also acquire data from other projects. By segregating the indexing procedure, Aleph.im ensures Solana projects save up on resources, and storage, and improve data accessibility speed.

To understand how a decentralized Solana indexing solution works on Aleph.im, let us illustrate it with an example. We will use the example of Raydium, an automated market maker (AMM) on the Solana blockchain.

The data flow in Raydium

The following steps will demonstrate how Aleph.im indexes data to create a Raydium dashboard for users.

  • Developers host the Raydium dApp code on the Aleph.im IPFS network
  • Users open Raydium and click on a button to request data for their usage
  • The Aleph.im API gateway processes the request and triggers a microVM
  • The microVM extracts the on-chain data, indexes it on GraphQL, and returns the data back to the user via the API
  • The microVM is continuously fetching/indexing data, even if there’s no user request for that data. This makes the most recent data always quickly available
  • Aleph.im adds the data to its decentralized database and stores the index on the node for future usage
A GraphQL output example

Solana protocols using the Aleph.im decentralized indexing solution

Some protocols in the Solana ecosystem are already benefiting from Aleph.im’s indexing technologies. The following is a non-exhaustive list of protocols using Aleph.im’s decentralized indexing solutions. As you read, Aleph.im is working with other blockchain protocols to onboard them for decentralized indexing.

Raydium

Raydium is a DeFi protocol and AMM on the Solana blockchain for swapping cryptocurrencies, providing liquidity to liquidity pools, and earning yields. Aleph.im’s decentralized indexing solutions provide data to Raydium users about token swaps, liquidity provisions, token prices, and total volume locked (TVL) across trading pairs. Aleph.im’s indexing technology plays a crucial role in providing data analytics to the Raydium protocol.

Serum

Serum is a Solana-based trustless, permissionless DeFi protocol for decentralized exchanges that offers on-chain order books for smooth crypto trading. Aleph.im provides TVL, trading history, daily active users and “searchable data on specific market addresses, open orders accounts, and owner addresses” to Serum. With Aleph.im’s indexing services, investors can better analyze the influx of funds from different users, thereby enriching the Solana DeFi ecosystem.

PsyOptions

PsyOptions is an open and permissionless American and European style options market on the Solana blockchain. Aleph.im’s decentralized indexing solutions will make data about options markets, option token mints, and total volume available to PsyOptions.

Saber

Saber is an automated market maker (AMM) for trading stablecoins, wrapped cryptocurrencies, and other pegged assets. Aleph.im’s indexing solution provides data about token swaps, crypto prices, liquidity and TVL to Saber users.

Orca

Orca is a Solana-based AMM protocol offering fast token swaps, low transaction fees, and a user-friendly trading interface. Aleph.im’s decentralized indexers provide crucial trading data to Orca such as price line charts, trading volume of trading pairs, and TVL for liquidity pools

Port Finance

Port Finance is a lending protocol on Solana that offers variable and fixed rate lending, and interest rate swaps. Aleph.im will provide datasets like total borrowed value, loan-to-value ratio, borrowing costs, and flash loan fees on Port Finance.

Swim

Swim is a multi-chain liquidity protocol for transferring tokens across blockchain networks through multi-token liquidity pools. Aleph.im provides a data history of user transactions, capital flows, and total liquidity in liquidity pools for investors.

Friktion

Friktion is an automated portfolio manager (APM) that offers optimal investment products to generate greater yields. Aleph.im’s indexing solution offers transparent data on user deposits, withdrawals, and profits earned on the platform.

Katana

Katana is a yield generation platform on the Solana blockchain that empowers investors to earn better yields on their crypto investments. Aleph.im provides data insights for Katana’s option vaults so that investors can analyse them to make intelligent investment decisions.

Neon

Neon is an Ethereum Virtual Machine that enables Ethereum dApps to scale and access Solana’s liquidity. Aleph.im provides data about transactions per second (TPS), smart contracts, and operator node statistics. Developers can also access past events, and track transaction transfers to further develop interoperable protocols.

What makes Aleph.im’s Solana indexing solution better than others?

There are several factors that make Aleph.im a better choice to index data for the Solana blockchain.

  • Cost-effective: Aleph.im provides an economical solution for indexing Solana’s on-chain data. Unlike other indexers that rely on expensive hardware and computing resources, Aleph.im’s microVM technology makes indexing cheaper.
  • Time-saving: Aleph.im’s decentralized indexing solution saves time to index data. Most other indexers try to index data for the whole blockchain at once, which becomes time-consuming. However, Aleph’s wide microVM network segregates the indexing process, thereby speeding up the indexing process.
  • More scalability: Aleph.im’s microVM network will soon spawn additional indexer instances when it detects a spike in network activity. On-demand indexer spawning, and auto-syncing the data for permanent storage on Aleph.im’s network make indexing scalable.
  • Enhanced security: Aleph.im has a large distributed network of nodes that offers better security and reliability to indexed data. Unlike other indexers that often host their nodes on centralized servers, Aleph.im runs on independent nodes. Thus, there is no central point of failure.
  • Better decentralization: Aleph.im’s indexing solution decentralizes the whole stack and removes any reliance on centralized infrastructure.
  • Censorship-resistant: As a completely decentralized technology, Aleph.im ensures zero censorship from any central management authorities.
  • Less exploitable: Unlike other decentralized indexers that may be prone to vulnerabilities, Aleph.im’s open-source, auditable code makes it less exploitable.
  • Self-deployable: Deploying Aleph.im’s Solana indexer is easy and anyone can do it. Most other decentralized indexers require complex coding knowledge to deploy them. However, Aleph.im’s simple self-deployment setup not only saves dApp development hours but also reduces the time to market.

Aleph.im: The future of Solana’s decentralized indexing solutions

Aleph.im is a production-ready computing network that has already provided decentralized technological solutions for companies like Ubisoft, Polygon, Synaps, and Request. Aleph.im is on mission speed to facilitate decentralization for transitioning to Web3. To this end, Aleph.im has raised $10 million in a funding round to further scale its storage and computing network.

Aleph.im aims to become the one-stop destination for all kinds of Solana indexing solutions. With its diverse arsenal of advanced technologies, Aleph.im is already on its way to becoming the future of blockchain indexing.

Thanks and keep in touch

Join our live conversation on our Telegram Community Chat.

🌴 Linktr.ee | 🌐 Website | 🗞 Blog | 📄 Papers | 🐦 Twitter | 💬 Telegram |
💼 Linkedin | 💻 GitHub | 📒 Dev Docs | 🤖 Reddit

--

--