Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(rpc): measure request/call time in seconds #5361

Merged
merged 2 commits into from
Nov 8, 2023

Conversation

shekhirin
Copy link
Collaborator

@shekhirin shekhirin commented Nov 8, 2023

Updated dashboard

image

Changes

  1. Show Active connections instead of Active requests, because requests may end up without responses hence without symmetrical finished metric. In that case we'll have this metric > 0, even though currently no requests are in processing.
  2. Add Maximum call latency per method chart to help figure out what methods take too long.
  3. Fix all heatmaps.

RPC duration reported in seconds instead of milliseconds

ubuntu@bench-box:~/reth-mainnet$ cast bn
18528468

ubuntu@bench-box:~/reth-mainnet$ curl -s localhost:9001/metrics | grep 'blockNumber'
reth_rpc_server_calls_failed{method="eth_blockNumber"} 0
reth_rpc_server_calls_successful{method="eth_blockNumber"} 1
reth_rpc_server_calls_started{method="eth_blockNumber"} 1
reth_rpc_server_calls_time_seconds{method="eth_blockNumber",quantile="0"} 0.000035252
reth_rpc_server_calls_time_seconds{method="eth_blockNumber",quantile="0.5"} 0.0000352551112514506
reth_rpc_server_calls_time_seconds{method="eth_blockNumber",quantile="0.9"} 0.0000352551112514506
reth_rpc_server_calls_time_seconds{method="eth_blockNumber",quantile="0.95"} 0.0000352551112514506
reth_rpc_server_calls_time_seconds{method="eth_blockNumber",quantile="0.99"} 0.0000352551112514506
reth_rpc_server_calls_time_seconds{method="eth_blockNumber",quantile="0.999"} 0.0000352551112514506
reth_rpc_server_calls_time_seconds{method="eth_blockNumber",quantile="1"} 0.000035252
reth_rpc_server_calls_time_seconds_sum{method="eth_blockNumber"} 0.000035252
reth_rpc_server_calls_time_seconds_count{method="eth_blockNumber"} 1

@shekhirin shekhirin added C-enhancement New feature or request A-rpc Related to the RPC implementation A-observability Related to tracing, metrics, logs and other observability tools labels Nov 8, 2023
Copy link
Collaborator

@mattsse mattsse left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

will a <1s call show up as 0?

@shekhirin
Copy link
Collaborator Author

@mattsse nope it's fine, see logs in the PR description

@shekhirin shekhirin marked this pull request as ready for review November 8, 2023 17:01
Copy link
Collaborator

@mattsse mattsse left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@shekhirin shekhirin added this pull request to the merge queue Nov 8, 2023
Merged via the queue into main with commit e056bfb Nov 8, 2023
25 checks passed
@shekhirin shekhirin deleted the alexey/rpc-metrics-seconds branch November 8, 2023 17:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-observability Related to tracing, metrics, logs and other observability tools A-rpc Related to the RPC implementation C-enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants