Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
tikvclient: add metrics for gRPC connection transient failure (#12084) #12093
Signed-off-by: Lonng firstname.lastname@example.org
Cherry-pick #12084 for release-3.0
What problem does this PR solve?
TiDB access to TiKV through gRPC requests. If the underlying socket is disconnected, gRPC will try to reconnect to the underlying socket, which may cause the request delay to jitter. We need to way to monitor the low-level socket state change.
What is changed and how it works?
This PR adds a metric to monitor the gRPC connection state, the metric will record the connection state before sending the request to TiKV. We can diagnose the delay jitter by