[Blockchain Watcher] (FIX - ALGORAND) Mapped grafana config to source events (#1507)
Mapped grafana config to source events Co-authored-by: julian merlo <julianmerlo@julians-MacBook-Pro-2.local>
This commit is contained in:
parent
6f7d457386
commit
7bdc71cd62
|
@ -27,23 +27,27 @@ export class HandleAlgorandTransactions {
|
|||
}
|
||||
|
||||
private report(protocol: string) {
|
||||
const labels = {
|
||||
if (!this.cfg.metricName) return;
|
||||
|
||||
const labels = this.cfg.metricLabels ?? {
|
||||
job: this.cfg.id,
|
||||
chain: "algorand",
|
||||
protocol: protocol ?? "unknown",
|
||||
protocol: protocol,
|
||||
commitment: "latest",
|
||||
};
|
||||
|
||||
this.statsRepo.count(this.cfg.metricName, labels);
|
||||
}
|
||||
}
|
||||
|
||||
export interface HandleAlgorandTransactionsOptions {
|
||||
metricLabels?: { job: string; chain: string; commitment: string };
|
||||
metricName: string;
|
||||
filter: Filter[];
|
||||
id: string;
|
||||
}
|
||||
|
||||
type Filter = {
|
||||
applicationIds: string;
|
||||
applicationAddress: string;
|
||||
applicationIds: string;
|
||||
};
|
||||
|
|
|
@ -132,7 +132,12 @@ data:
|
|||
"applicationIds": "86525623",
|
||||
"applicationAddress": "C2SZBD4ZFFDXANBCUTG5GBUEWMQ34JS5LFGDRTEVJBAXDRF6ZWB7Q4KHHM"
|
||||
}
|
||||
]
|
||||
],
|
||||
"metricLabels": {
|
||||
"job": "poll-log-message-published-algorand",
|
||||
"chain": "algorand",
|
||||
"commitment": "latest"
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
|
@ -241,7 +246,12 @@ data:
|
|||
"applicationIds": "842125965",
|
||||
"applicationAddress": "J476J725L4JTOI2YU6DAI4E23LYUECLZR7RCYZ3LK6QFHX4M54ZI53SGXQ"
|
||||
}
|
||||
]
|
||||
],
|
||||
"metricLabels": {
|
||||
"job": "poll-log-message-published-algorand",
|
||||
"chain": "algorand",
|
||||
"commitment": "latest"
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
|
|
Loading…
Reference in New Issue