Provides an interface for metrics recording. The implementer is expected to use an observability
framework, e.g. OpenTelemetry. There should be only one instance of MetricsRecorder per client,
all the methods in this class are expected to be called from multiple threads, hence the
implementation must be thread safe.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-04 UTC."],[[["\u003cp\u003eThis webpage details the \u003ccode\u003eMetricsRecorder\u003c/code\u003e interface in the Google API Client Library for Java (gax), with version 2.63.1 being the most recent release, and the currently displayed version being 2.62.0.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eMetricsRecorder\u003c/code\u003e interface is designed for recording metrics using an observability framework, and it is thread-safe, allowing multiple threads to call its methods.\u003c/p\u003e\n"],["\u003cp\u003eThe interface provides methods for recording RPC attempt counts (\u003ccode\u003erecordAttemptCount\u003c/code\u003e), RPC attempt latency (\u003ccode\u003erecordAttemptLatency\u003c/code\u003e), operation counts (\u003ccode\u003erecordOperationCount\u003c/code\u003e), and total operation latency (\u003ccode\u003erecordOperationLatency\u003c/code\u003e).\u003c/p\u003e\n"],["\u003cp\u003eEach of the methods for recording metrics takes a value and a map of string attributes as parameters, where \u003ccode\u003ecount\u003c/code\u003e and \u003ccode\u003eoperationLatency\u003c/code\u003e or \u003ccode\u003eattemptLatency\u003c/code\u003e utilize Java's long and double types, respectively.\u003c/p\u003e\n"],["\u003cp\u003eThe library is in beta, might have limited support, and changes might not be compatible with other pre-GA versions.\u003c/p\u003e\n"]]],[],null,[]]