Sha256: 8a53488e5fe016dc11c7796b67b62c61156b67819b94aaf7626b39a447f11102
Contents?: true
Size: 923 Bytes
Versions: 8
Compression:
Stored size: 923 Bytes
Contents
module Riak::TimeSeries class Submission # @!attributes [rw] measurements # @return [Array<Array<Object>>] measurements to write to Riak TS attr_accessor :measurements # @!attribute [r] client # @return [Riak::Client] the client to write submissions to attr_reader :client # @!attribute [r] table_name # @return [String] the table name to write submissions to attr_reader :table_name # Initializes the submission object with a client and table name # # @param [Riak::Client] client the client connected to the Riak TS cluster # @param [String] table_name the table name in the cluster def initialize(client, table_name) @client = client @table_name = table_name end # Write the submitted data to Riak. def write! client.backend do |be| be.time_series_put_operator.put(table_name, measurements) end end end end
Version data entries
8 entries across 8 versions & 1 rubygems