Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(bigquery/storage/managedwriter): refactor error metrics (#8314)
This is a small refactor to how opencensus metrics are reported when receiving responses from the server. There's effectively two cases where we consider an error to have occurred on receive: * Invoking gRPC Recv() on the connection emitted an error, typically a transport issue * The service embedded an error in the response, which is more akin to an application error (failed to commit data, offset mismatch, etc). This CL ensures we increment the existing AppendResponseError count metric in both causes, and deals with the unlikely scenario where we're unable to tag the report with the status code. When that happens, we simply record the metric uncoded. Towards: https://github.com/googleapis/google-cloud-go/issues/8311
- Loading branch information