hyperledger / cacti

Hyperledger Cacti is a new approach to the blockchain interoperability problem
https://wiki.hyperledger.org/display/cactus
Apache License 2.0
339 stars 277 forks source link

SATP gateway monitoring and dashboard #3124

Open RafaelAPB opened 5 months ago

RafaelAPB commented 5 months ago

Extend the SATP codebase to use Prometheus to get some important metrics on the state of a SATP gateway. An administrator should be able to access a dashboard that contains the state of the gateway.

Currently some Cacti plugins support some metric management on Prometheus. Example: Ethereum connector, Fabric connector and many more. See an example on how to instantiate prometheus here, define metrics, and to update metrics. We should also explore using OpenTelemetry to replace or complement Prometheus.

Requirements: 1- Explore OpenTelemetry as a technical solution for the list of metrics below. 1 - In order to monitor SATP-Hermes effectively, we need to add support for Prometheus, by defining the following metrics (and tracking them in the corresponding code): -number of supported assets -total number of successful transactions -total number of failed transactions -successful transactions per SATP phase -failed transactions per SATP phase -total peer gateways -total number of sessions -number of sessions with each gateway -total value transferred -value transferred per gateway -number of blockchain transactions done successfully -number of failed blockchain transactions -amount of blockchain transaction fees paid -track transaction IDs (hashes) for every blockchain transaction for later inspection

-transfers initiated (and which id) -transfers in progress -transfers cancelled -number of crashes -number of recoveries -average time to recovery -average time to crash -number of rollbacks

2- SATP-Hermes should define an endpoint that exposes these metrics

3- Use this endpoint to instantiate Grafana to visualize relevant metrics. See this example.

The Grafana dashboards that point to the prometheus / open telemetry endpoints should be instantiated on the SATP dockerfile. The dashboard should be accessible on a browser via docker.

LordKubaya commented 5 months ago

hi

eduv09 commented 2 months ago