Mainnet release of TAP and indexer-service-rs

Announcement: Mainnet release of TAP and indexer-service-rs

Today we are releasing the new TAP micro-payment protocol on The Graph!

TL;DR - The Indexer software stack is evolving to become faster and more feature-rich. Indexers will need to upgrade to TAP before Scalar, the existing payment protocol, becomes deprecated.

What is TAP?

The Timeline Aggregation Protocol is the new micro-payments system for queries on The Graph, replacing Scalar. It is high-throughput, efficient and trust-minimized, and allows further decentralization of The Graph Network by reducing the Indexers’ need for trust in the gateways.

Legend: TAP depends on Indexers to store all the receipts from the gateways. Receipts are not redeemable onchain, but Indexers can repeatedly request RAVs (Receipt Aggregate Voucher) from the gateways by showing a batch of valid receipts. RAVs are redeemable onchain, and release the correct amount of GRT held in escrow from the gateway.

For a more detailed explanation of the TAP protocol, please refer to:

What changed?

Please watch this video for an overview of the new Indexer stack components and how they interact:

Indexer Office Hours #147

indexer-service-rs

indexer-service-rs is a rewrite of the indexer-service in Rust that enables better performance and maintainability and only uses the TAP protocol for gateway micro-payments. Switching to indexer-service-rs will improve your Indexer’s stability and performance, encouraging gateways to send more queries to your Indexer. Note that the old indexer-service does not support TAP and will soon be deprecated.

Gateway

The gateway has been upgraded to support TAP payments when it detects that an Indexer runs an indexer-service version greater or equal to 1.0.0, which stands for the new Rust version. Until Scalar is deprecated, the gateway will (soon) retain backward compatibility with it.

tap-aggregator

tap-aggregator is run by the sender (gateway operator), it lets Indexers request RAVs (Receipt Aggregate Vouchers) in exchange for valid receipt batches. Only RAVs can be redeemed onchain.

indexer-agent

indexer-agent has also been upgraded to support redeeming RAVs for Indexers to receive an onchain payment of their earned query fees after allocation closure. Until Scalar is deprecated, it will retain backward compatibility and continue operating as usual until it is provided with a --tap-subgraph-endpoint.

tap-agent

tap-agent is a new component that must be continuously run alongside the new indexer-service-rs. It tracks query fees for each sender (i.e., gateway), ensuring accounts are in good standing. It also automatically requests receipt aggregates from each sender. If, for some reason, accounts are not in good standing, it will deny the senders until the issue is resolved.

Action items for Indexers

Scalar is not deprecated yet, but it will happen soon. So please start getting familiar with the new components, experiment on the arbitrum-sepolia testnet, and migrate your mainnet stack as soon as you feel comfortable.

Refer to the migration docs here: TAP Migration Guide | Docs | The Graph

Also, do not hesitate to ask questions in Discord (indexer-software channel), where Semiotic Labs and dev/test partners InfraDAO, DataNexus, Pinax, GraphOps, and E&N will help you get started.

Sources

TAP protocol presentation: https://www.youtube.com/watch?v=_tBX-Y9xgNg&t=269s

New Indexer stack presentation: https://youtu.be/NwovWSPB4tI?t=895

TAP GIP: GIP-0054: Timeline Aggregation Protocol

TAP migration docs: TAP Migration Guide | Docs | The Graph

Repos:

5 Likes

This is incredibly cool. Thank you to everyone that has worked on this. The prospect of trustless gateways is now very real!

Documentation is excellent, just picked up on one small error here where the chain names in the table headers are the wrong way round, if I am reading correctly.

3 Likes