mirror of
https://github.com/cerc-io/watcher-ts
synced 2026-09-08 00:44:06 +00:00
Fetch event logs for a block range in a single upstream call (#433)
* Support fetching logs for a block range in rpc-eth-client * Add a method to fetch block events for multiple blocks at once * Add a method to save blocks with fetched events in a block range * Fix transactions destructuring * Fix get logs call args * Add a separate ETH client method to get logs in a block range * Codegen changes
This commit is contained in:
@@ -106,6 +106,12 @@ export class Indexer implements IndexerInterface {
|
||||
return '';
|
||||
}
|
||||
|
||||
async fetchEventsAndSaveBlocks (blocks: DeepPartial<BlockProgressInterface>[]): Promise<{ blockProgress: BlockProgressInterface, events: DeepPartial<EventInterface>[] }[]> {
|
||||
assert(blocks);
|
||||
|
||||
return [];
|
||||
}
|
||||
|
||||
async saveBlockAndFetchEvents (block: BlockProgressInterface): Promise<[BlockProgressInterface, DeepPartial<EventInterface>[]]> {
|
||||
return [block, []];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user