coinbase / coinbase/mesh-cli

Instrumentation for outbound rosetta client request/responses to track slow or failing endpoints

Open
#390 1 comment 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Go
Stars
165
Forks
99
PR merge metrics
No merged PRs in 30d

Description

**Is your feature request related to a problem? Please describe.**
Currently, there is no instrumentation support in `rosetta-cli`. Adding flag to enable instrumentation should start tracing outbound requests to measure their response time, error percentages, p99, p95, p50 etc
We can add an enable-request-instrumentation flag in config.json to enable or disable instrumentation.

**Describe the solution you'd like**
If we can integrate some instrumentation library such as [open telemetry](https://opentelemetry.io/docs/) in rosetta-cli, we can instrument request/response of rosetta endpoints.

We would be able to see slow and error requests.

**Describe alternatives you've considered**
Problems with current performance tooling:

1. `check:perf`
It needs to be run as a separate process and measure results for `/block` and `/account/balance` endpoint.
`/account/balance` is not using "address" value from blocks but is using hard-coded "address" string which is why all of requests fail due to address validation.
2. `--block-profile`
It is great to measure block pprof data but does not shows which requests failed or are slow.

**Additional context**
Adding instrumentation could potentially slow down the process which is why it is important to have enable/disable configuration added for it.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.