lib/bm/instrumentations/aws/metrics_collection.rb
def record_api_call(api_call)
          duration = api_call.latency / MS_IN_SECOND
          labels = default_labels_for(api_call)

          requests_total.increment(labels: labels)
          request_duration_seconds.observe(duration, labels: labels)
          increment_exceptions_total(api_call) if api_call.final_aws_exception
          increment_retries_total(api_call) if api_call.attempt_count > 1
        end
# Records a metrics for given API Call
#
# @param api_call [Aws::ClientSideMonitoring::RequestMetrics::ApiCall]
Records a metrics for given API Call
Records a metrics for given API Call
def record_api_call(api_call)
          duration = api_call.latency / MS_IN_SECOND
          labels = default_labels_for(api_call)
          requests_total.increment(labels: labels)
          request_duration_seconds.observe(duration, labels: labels)
          increment_exceptions_total(api_call) if api_call.final_aws_exception
          increment_retries_total(api_call) if api_call.attempt_count > 1
        end
def record_api_call ( api_call ) duration = api_call . latency / MS_IN_SECOND labels = default_labels_for ( api_call ) requests_total . increment ( labels : labels ) request_duration_seconds . observe ( duration , labels : labels ) increment_exceptions_total ( api_call ) if api_call . final_aws_exception increment_retries_total ( api_call ) if api_call . attempt_count > 1 end
Records a metrics for given API Call
Records a metrics for given API Call
api_call
None