Skip to content

tolak/subbridge-metrics

Repository files navigation

SubBridge Metrics services

Supportecd metrics services

  • Return reserve balance of tokens defined in token.json
  • Return time spend in minutes of chainbridge transfer send from Khala to Ethereum

How to run

Step1: Setup a start height of khala network in config.json, will fetch events begin with this block

Step2: Set environment variables, you can create an .env file under project root directory, it should contain following items:

ONFINALITY_API_KEY=<your Onfinality API key>
INFURA_API_KEY=<your Infura API key>
PORT=3001   // metrics service listen port

UPDATE_INTERVAL=30000 // interval task period time in milliseconds

Step3: Issue following command to start service

yarn & node index.js

Integrate into your prometheus service

Export the service and set custom metrics url in your prometheus config file, then you can add it as a data source into your grafana.

About

Metrics service of Phala Subbridge

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published