Latias::Influxdb
Ruby lib for use influxdb version 2 on Ruby language
Usage
class MdbEnergyBucket < Latias::Influxdb::Bucket
def initialize
@url = 'http://localhost:8086'
@token = 'your token'
@bucket = 'MDBEnergy'
@org = 'MDBEnergy'
@use_ssl = false
@verify_mode = OpenSSL::SSL::VERIFY_NONE
@precision = InfluxDB2::WritePrecision::NANOSECOND
@client = client
end
end
mdb_energy_bucket = MdbEnergyBucket.new
mdb_energy_bucket.range('start: -1m').filter('fn: (r) => r["_measurement"] == "cpu"')
mdb_energy_bucket.call
Installation
Add this line to your application's Gemfile:
gem 'latias-influxdb'
And then execute:
$ bundle
Or install it yourself as:
$ gem install latias-influxdb
Contributing
Contribution directions go here.
License
The gem is available as open source under the terms of the MIT License.