Systems and methods for improved blockchain data indexing by avoiding throughput bottlenecks
AssigneeCoinbase, Inc.
InventorsJie Zhang, Zhicong Liang, Yaohua Yang, David Lai, Chaoqing Lu, Jinghan Xu, Xu Meng
Life of this patent
Estimating the term…
Abstract
Systems and methods for a unified approach that is compatible with all blockchains, protocols, etc. The systems and methods use a bifurcated indexing system with a dynamically selected application service. The systems and methods bifurcate the indexing process into a storage layer and a compute layer.
Claims20
A system for improved blockchain data indexing by avoiding throughput bottlenecks caused by reliance on a single blockchain node, the system comprising:
- one or more processors and media storing instructions that, when executed by the one or more processors, cause operations comprising:
- designating a first blockchain node of a plurality of blockchain nodes for a blockchain network as having a first node type;
- based on designating the first blockchain node of the plurality of blockchain nodes as having the first node type, establishing a session with the first blockchain node:
- while maintaining the session:
- determining an order of a first block and a second block on a canonical chain of the blockchain network;
- designating a second blockchain node and a third blockchain node of the plurality of blockchain nodes as having a second node type;
- based on designating the second blockchain node and the third blockchain node of the plurality of blockchain nodes as having the second node type, transmitting, in parallel, queries to the second blockchain node and the third blockchain node for first on-chain data from the first block and second on-chain data from the second block, respectively, wherein the first on-chain data and the second on-chain data comprise hexadecimal encoded data;
- and
- receiving the first on-chain data or the second on-chain data;
- transforming the first on-chain data and the second on-chain data to a first format, wherein the first format comprises data types with field names identified by a respective integer;
- and
- storing the transformed first on-chain data and the transformed second on-chain data in a first dataset at a blockchain-interface layer, wherein the first dataset comprises the hexadecimal encoded data and uses the first format.
A method for improved blockchain data indexing by avoiding throughput bottlenecks caused by reliance on a single blockchain node, the method comprising:
- designating a first blockchain node of a plurality of blockchain nodes for a blockchain network as having a first node type;
- based on designating the first blockchain node of the plurality of blockchain nodes as having the first node type, establishing a session with the first blockchain node;
- determining an order of a first block and a second block on a canonical chain of the blockchain network;
- designating a second blockchain node and a third blockchain node of the plurality of blockchain nodes as having a second node type;
- based on designating the second blockchain node and the third blockchain node of the plurality of blockchain nodes as having the second node type, transmitting, in parallel, queries to the second blockchain node and the third blockchain node for first on-chain data from the first block and second on-chain data from the second block, respectively;
- receiving the first on-chain data or the second on-chain data;
- and
- in response to receiving the first on-chain data or the second on-chain data, indexing, in a first dataset, the first on-chain data or the second on-chain data based on the order of the first block and the second block on the canonical chain.
One or more non-transitory computer-readable media having instructions recorded thereon that, when executed by one or more processors, cause operations comprising:
- designating a first blockchain node of a plurality of blockchain nodes for a blockchain network as having a first node type;
- based on designating the first blockchain node of the plurality of blockchain nodes as having the first node type, establishing a session with the first blockchain node;
- determining an order of a first block and a second block on a canonical chain of the blockchain network;
- designating a second blockchain node and a third blockchain node of the plurality of blockchain nodes as having a second node type;
- based on designating the second blockchain node and the third blockchain node of the plurality of blockchain nodes as having the second node type, transmitting, in parallel, queries to the second blockchain node and the third blockchain node for first on-chain data from the first block and second on-chain data from the second block, respectively;
- receiving the first on-chain data or the second on-chain data;
- and
- in response to receiving the first on-chain data or the second on-chain data, indexing, in a first dataset, the first on-chain data or the second on-chain data based on the order of the first block and the second block on the canonical chain.
Dependencies are inferred from the claim text.