查询事件时,每次只查一个topic, 修正redeem事件名的错误
This commit is contained in:
parent
4ce4eac368
commit
1bcdd0879c
@ -42,7 +42,7 @@
|
|||||||
{
|
{
|
||||||
"chain": 421614,
|
"chain": 421614,
|
||||||
"address": "0xd46fA2E72BA0F54092D0eF6a6e0D1d5660259C7a",
|
"address": "0xd46fA2E72BA0F54092D0eF6a6e0D1d5660259C7a",
|
||||||
"event": "Staked",
|
"event": "Redeem",
|
||||||
"abi": "NFT_Redeem",
|
"abi": "NFT_Redeem",
|
||||||
"fromBlock": 3549891,
|
"fromBlock": 3549891,
|
||||||
"eventProcesser": "NftStake"
|
"eventProcesser": "NftStake"
|
||||||
|
@ -62,7 +62,7 @@ export class EventBatchSvr {
|
|||||||
params.push(_param)
|
params.push(_param)
|
||||||
} else {
|
} else {
|
||||||
let _param = uninParams[uninParams.length - 1]
|
let _param = uninParams[uninParams.length - 1]
|
||||||
if (!_param || topicsSet.size > MAX_TOPICS) {
|
if (!_param || topicsSet.size > 1) {
|
||||||
_param = this.buildQueryParams(cfg, toBlock)
|
_param = this.buildQueryParams(cfg, toBlock)
|
||||||
uninParams.push(_param)
|
uninParams.push(_param)
|
||||||
topicsSet = new Set()
|
topicsSet = new Set()
|
||||||
|
@ -4,7 +4,7 @@ import logger from "logger/logger";
|
|||||||
import { RedisClient } from "redis/RedisClient";
|
import { RedisClient } from "redis/RedisClient";
|
||||||
import { utf8ToHex } from "./string.util";
|
import { utf8ToHex } from "./string.util";
|
||||||
|
|
||||||
const MAX_BATCH_AMOUNT = 500
|
const MAX_BATCH_AMOUNT = +process.env.MAX_BLOCK_BATCH_AMOUNT
|
||||||
const REQUEST_INTERVAL = 0.5 * 1000
|
const REQUEST_INTERVAL = 0.5 * 1000
|
||||||
|
|
||||||
export async function divQueryPassBlocks({chainId, rpc, fromBlock, amount}
|
export async function divQueryPassBlocks({chainId, rpc, fromBlock, amount}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user