Sha256: 5d767327fffca71b8fb422efeea5290942add978634ad667c6db1074276e82e3

Contents?: true

Size: 1.42 KB

Versions: 22

Compression:

Stored size: 1.42 KB

Contents

require 'fog/core/collection'
require 'fog/google/models/monitoring/timeseries'

module Fog
  module Google
    class Monitoring
      class TimeseriesCollection < Fog::Collection
        model Fog::Google::Monitoring::Timeseries

        ##
        # Lists all Timeseries.
        #
        # @param [String] metric The name of the metric (Metric names are protocol-free URLs).
        # @param [String] youngest End of the time interval (inclusive), which is expressed as an RFC 3339 timestamp.
        # @param [Hash] options Optional query parameters.
        # @option options [String] count Maximum number of time series descriptors per page. Used for pagination.
        # @option options [String] labels A collection of labels for the matching time series.
        # @option options [String] oldest Start of the time interval (exclusive), which is expressed as an RFC 3339
        #   timestamp.
        # @options options [String] page_token The pagination token, which is used to page through large result sets.
        # @options options [String] timespan Length of the time interval to query, which is an alternative way to
        #   declare the interval.
        # @return [Array<Fog::Google::Monitoring::Timeseries>] List of Timeseries.
        def all(metric, youngest, options = {})
          data = service.list_timeseries(metric, youngest, options).body['timeseries'] || []
          load(data)
        end
      end
    end
  end
end

Version data entries

22 entries across 20 versions & 5 rubygems

Version Path
vagrant-packet-0.1.1 vendor/bundle/ruby/2.5.0/gems/fog-google-0.1.0/lib/fog/google/models/monitoring/timeseries_collection.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.4.0/gems/fog-google-0.1.0/lib/fog/google/models/monitoring/timeseries_collection.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.3.0/gems/fog-google-0.1.0/lib/fog/google/models/monitoring/timeseries_collection.rb
fog-google-0.1.3 lib/fog/google/models/monitoring/timeseries_collection.rb
fog-google-0.1.2 lib/fog/google/models/monitoring/timeseries_collection.rb
fog-google-0.1.1 lib/fog/google/models/monitoring/timeseries_collection.rb
fog-google-0.1.0 lib/fog/google/models/monitoring/timeseries_collection.rb
fog-google-0.0.9 lib/fog/google/models/monitoring/timeseries_collection.rb
vagrant-cloudstack-1.2.0 vendor/bundle/gems/fog-google-0.0.7/lib/fog/google/models/monitoring/timeseries_collection.rb
fog-google-0.0.7 lib/fog/google/models/monitoring/timeseries_collection.rb
fog-google-0.0.6 lib/fog/google/models/monitoring/timeseries_collection.rb
fog-google-0.0.5 lib/fog/google/models/monitoring/timeseries_collection.rb
fog-google-0.0.4 lib/fog/google/models/monitoring/timeseries_collection.rb
fog-google-0.0.3 lib/fog/google/models/monitoring/timeseries_collection.rb
fog-google-0.0.2 lib/fog/google/models/monitoring/timeseries_collection.rb
fog-1.29.0 lib/fog/google/models/monitoring/timeseries_collection.rb
fog-1.28.0 lib/fog/google/models/monitoring/timeseries_collection.rb
fog-1.27.0 lib/fog/google/models/monitoring/timeseries_collection.rb
fog-1.26.0 lib/fog/google/models/monitoring/timeseries_collection.rb
fog-1.25.0 lib/fog/google/models/monitoring/timeseries_collection.rb