Skip to content

Commit

Permalink
chore: update metrics & flags in readme
Browse files Browse the repository at this point in the history
  • Loading branch information
MattKetmo committed Nov 15, 2024
1 parent 1bf8650 commit a728e21
Showing 1 changed file with 50 additions and 42 deletions.
92 changes: 50 additions & 42 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,25 +64,27 @@ COMMANDS:
help, h Shows a list of commands or help for one command
GLOBAL OPTIONS:
--chain-id value to ensure all nodes matches the specific network (dismiss to auto-detected)
--http-addr value http server address (default: ":8080")
--log-level value log level (debug, info, warn, error) (default: "info")
--namespace value namespace for Prometheus metrics (default: "cosmos_validator_watcher")
--no-color disable colored output (default: false)
--node value [ --node value ] rpc node endpoint to connect to (specify multiple for high availability) (default: "http://localhost:26657")
--no-gov disable calls to gov module (useful for consumer chains) (default: false)
--no-staking disable calls to staking module (useful for consumer chains) (default: false)
--no-commission disable calls to get validator commission (useful for chains without distribution module) (default: false)
--no-upgrade disable calls to upgrade module (for chains created without the upgrade module) (default: false)
--denom value denom used in metrics label (eg. atom or uatom)
--denom-exponent value denom exponent (eg. 6 for atom, 1 for uatom) (default: 0)
--start-timeout value timeout to wait on startup for one node to be ready (default: 10s)
--stop-timeout value timeout to wait on stop (default: 10s)
--validator value [ --validator value ] validator address(es) to track (use :my-label to add a custom label in metrics & ouput)
--webhook-url value endpoint where to send upgrade webhooks (experimental)
--x-gov value version of the gov module to use (v1|v1beta1) (default: "v1")
--help, -h show help
--version, -v print the version
--chain-id value to ensure all nodes matches the specific network (dismiss to auto-detected)
--http-addr value http server address (default: ":8080")
--log-level value log level (debug, info, warn, error) (default: "info")
--namespace value namespace for Prometheus metrics (default: "cosmos_validator_watcher")
--no-color disable colored output (default: false)
--node value [ --node value ] rpc node endpoint to connect to (specify multiple for high availability) (default: "http://localhost:26657")
--no-gov disable calls to gov module (useful for consumer chains) (default: false)
--no-staking disable calls to staking module (useful for consumer chains) (default: false)
--no-slashing disable calls to slashing module (default: false)
--no-commission disable calls to get validator commission (useful for chains without distribution module) (default: false)
--no-upgrade disable calls to upgrade module (for chains created without the upgrade module) (default: false)
--denom value denom used in metrics label (eg. atom or uatom)
--denom-exponent value denom exponent (eg. 6 for atom, 1 for uatom) (default: 0)
--start-timeout value timeout to wait on startup for one node to be ready (default: 10s)
--stop-timeout value timeout to wait on stop (default: 10s)
--validator value [ --validator value ] validator address(es) to track (use :my-label to add a custom label in metrics & ouput)
--webhook-url value endpoint where to send upgrade webhooks (experimental)
--webhook-custom-block value [ --webhook-custom-block value ] trigger a custom webhook at a given block number (experimental)
--x-gov value version of the gov module to use (v1|v1beta1) (default: "v1")
--help, -h show help
--version, -v print the version
```


Expand All @@ -97,29 +99,35 @@ GLOBAL OPTIONS:

All metrics are by default prefixed by `cosmos_validator_watcher` but this can be changed through options.

Metrics (without prefix) | Description
---------------------------|-------------------------------------------------------------------------
`active_set` | Number of validators in the active set
`block_height` | Latest known block height (all nodes mixed up)
`commission` | Earned validator commission
`is_bonded` | Set to 1 if the validator is bonded
`is_jailed` | Set to 1 if the validator is jailed
`missed_blocks` | Number of missed blocks per validator (for a bonded validator)
`consecutive_missed_blocks`| Number of consecutive missed blocks per validator (for a bonded validator)
`node_block_height` | Latest fetched block height for each node
`node_synced` | Set to 1 is the node is synced (ie. not catching-up)
`proposal_end_time` | Timestamp of the voting end time of a proposal
`proposed_blocks` | Number of proposed blocks per validator (for a bonded validator)
`rank` | Rank of the validator
`seat_price` | Min seat price to be in the active set (ie. bonded tokens of the latest validator)
`skipped_blocks` | Number of blocks skipped (ie. not tracked) since start
`solo_missed_blocks` | Number of missed blocks per validator, unless the block is missed by many other validators
`tokens` | Number of staked tokens per validator
`tracked_blocks` | Number of blocks tracked since start
`transactions` | Number of transactions since start
`validated_blocks` | Number of validated blocks per validator (for a bonded validator)
`vote` | Set to 1 if the validator has voted on a proposal
`upgrade_plan` | Block height of the upcoming upgrade (hard fork)
Metrics (without prefix) | Description
--------------------------------|-------------------------------------------------------------------------
`active_set` | Number of validators in the active set
`block_height` | Latest known block height (all nodes mixed up)
`commission` | Earned validator commission
`consecutive_missed_blocks` | Number of consecutive missed blocks per validator (for a bonded validator)
`downtime_jail_duration` | Duration of the jail period for a validator in seconds
`is_bonded` | Set to 1 if the validator is bonded
`is_jailed` | Set to 1 if the validator is jailed
`min_signed_blocks_per_window` | Minimum number of blocks required to be signed per signing window
`missed_blocks` | Number of missed blocks per validator (for a bonded validator)
`missed_blocks_window` | Number of missed blocks per validator for the current signing window (for a bonded validator)
`node_block_height` | Latest fetched block height for each node
`node_synced` | Set to 1 is the node is synced (ie. not catching-up)
`proposal_end_time` | Timestamp of the voting end time of a proposal
`proposed_blocks` | Number of proposed blocks per validator (for a bonded validator)
`rank` | Rank of the validator
`seat_price` | Min seat price to be in the active set (ie. bonded tokens of the latest validator)
`signed_blocks_window` | Number of blocks per signing window
`skipped_blocks` | Number of blocks skipped (ie. not tracked) since start
`slash_fraction_double_sign` | Slash penaltiy for double-signing
`slash_fraction_downtime` | Slash penaltiy for downtime
`solo_missed_blocks` | Number of missed blocks per validator, unless the block is missed by many other validators
`tokens` | Number of staked tokens per validator
`tracked_blocks` | Number of blocks tracked since start
`transactions` | Number of transactions since start
`upgrade_plan` | Block height of the upcoming upgrade (hard fork)
`validated_blocks` | Number of validated blocks per validator (for a bonded validator)
`vote` | Set to 1 if the validator has voted on a proposal

For an example of a Prometheus and Grafana dashboard setup using Docker Compose, you can refer to [21state/cosmos-watcher-stack](https://github.com/21state/cosmos-watcher-stack/).

Expand Down

0 comments on commit a728e21

Please sign in to comment.