class Aws::Plugins::UserAgent
@api private
Constants
- METRICS
Public Class Methods
feature(_feature, &block)
click to toggle source
Deprecated - must exist for old service gems
# File lib/aws-sdk-core/plugins/user_agent.rb, line 52 def self.feature(_feature, &block) block.call end
metric(*metrics, &block)
click to toggle source
# File lib/aws-sdk-core/plugins/user_agent.rb, line 56 def self.metric(*metrics, &block) Thread.current[:aws_sdk_core_user_agent_metric] ||= [] metrics = metrics.map { |metric| METRICS[metric] }.compact Thread.current[:aws_sdk_core_user_agent_metric].concat(metrics) block.call ensure Thread.current[:aws_sdk_core_user_agent_metric].pop(metrics.size) end