module ScoutApm::BucketNameSplitter
Public Instance Methods
Source
# File lib/scout_apm/bucket_name_splitter.rb, line 7 def bucket_name split_metric_name(metric_name).last end
Source
# File lib/scout_apm/bucket_name_splitter.rb, line 3 def bucket_type split_metric_name(metric_name).first end
Source
# File lib/scout_apm/bucket_name_splitter.rb, line 11 def key {:bucket => bucket_type, :name => bucket_name} end
Private Instance Methods
Source
# File lib/scout_apm/bucket_name_splitter.rb, line 20 def scope_hash if scope scope_bucket, scope_name = split_metric_name(scope) {:bucket => scope_bucket, :name => scope_name} end end
Source
# File lib/scout_apm/bucket_name_splitter.rb, line 16 def split_metric_name(metric_name) metric_name.to_s.split(/\//, 2) end