influxer 1.2.0 → 1.4.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (44) hide show
  1. checksums.yaml +4 -4
  2. data/{Changelog.md → CHANGELOG.md} +26 -50
  3. data/{MIT-LICENSE → LICENSE.txt} +1 -1
  4. data/README.md +83 -24
  5. data/lib/influxer/client.rb +1 -1
  6. data/lib/influxer/config.rb +16 -3
  7. data/lib/influxer/metrics/metrics.rb +1 -1
  8. data/lib/influxer/metrics/relation/where_clause.rb +6 -0
  9. data/lib/influxer/metrics/relation.rb +16 -4
  10. data/lib/influxer/metrics/scoping/current_scope.rb +16 -2
  11. data/lib/influxer/rails/client.rb +5 -5
  12. data/lib/influxer/version.rb +1 -1
  13. data/lib/influxer.rb +4 -0
  14. metadata +13 -43
  15. data/.gitignore +0 -37
  16. data/.rspec +0 -2
  17. data/.rubocop.yml +0 -57
  18. data/.travis.yml +0 -15
  19. data/Gemfile +0 -13
  20. data/Rakefile +0 -15
  21. data/bin/console +0 -8
  22. data/gemfiles/rails32.gemfile +0 -7
  23. data/gemfiles/rails42.gemfile +0 -7
  24. data/gemfiles/rails5.gemfile +0 -7
  25. data/gemfiles/rails6.gemfile +0 -7
  26. data/influxer.gemspec +0 -40
  27. data/spec/cases/points_spec.rb +0 -36
  28. data/spec/cases/write_points_spec.rb +0 -85
  29. data/spec/client_spec.rb +0 -46
  30. data/spec/fixtures/empty_result.json +0 -21
  31. data/spec/fixtures/single_series.json +0 -29
  32. data/spec/metrics/metrics_spec.rb +0 -329
  33. data/spec/metrics/relation_spec.rb +0 -467
  34. data/spec/metrics/scoping_spec.rb +0 -66
  35. data/spec/model/user_spec.rb +0 -46
  36. data/spec/spec_helper.rb +0 -63
  37. data/spec/support/metrics/action_metrics.rb +0 -5
  38. data/spec/support/metrics/custom_metrics.rb +0 -6
  39. data/spec/support/metrics/dummy_metrics.rb +0 -12
  40. data/spec/support/metrics/user_metrics.rb +0 -6
  41. data/spec/support/metrics/visits_metrics.rb +0 -8
  42. data/spec/support/shared_contexts/shared_precision.rb +0 -19
  43. data/spec/support/shared_contexts/shared_query.rb +0 -16
  44. data/spec/support/user.rb +0 -16
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 020023da263e0ad14394211eaab3b6388359a2ebd8de084182eeddca8b4f7569
4
- data.tar.gz: 4648019961ea24ff2132d73b7975a801f0be0270380ba003223166191c4d924d
3
+ metadata.gz: fc1ab76fd0f5d70b0f876a0259d1d46cc3c8e878527a7aadf26c56834db55b55
4
+ data.tar.gz: 6f31a226c184219b583528d2f3f57d5482839f66dd6bec240ff8bf296360a9f3
5
5
  SHA512:
6
- metadata.gz: 3215b0bc249ad3e927f9f77dafb417c29c915c6b32f8f2342c6507b4d165f2a46b9aae82fe815ac374a2785f46c19020b6dd2688e8a208a79cc2a7e7060eb42c
7
- data.tar.gz: 70b27b50e9e98dcebde9b9ef4f16e1899c3f056770f31ece57af1c4c092a08ffa2484a4343e9c87795ffeca6b79553f9ab78a8dd431d40a75f0a2a808cf605b4
6
+ metadata.gz: 8661b96cded076dbf6674dd72ade16886ca18f375acdb8406b54a1cb89b25e10efd78aa70d90d1e26cab4dd8356ba57bb1fa2125107ebe07ca308f9b294d4d47
7
+ data.tar.gz: c7edf962257966dbbc829f0c9cd4dc0d8b924329c3ecd4ca689aaf61c54c6254e7c2f6f06e9b254131578945dcdf5dbceb292de85e934cdcda3bdfcae41393f0
@@ -2,6 +2,28 @@
2
2
 
3
3
  ## master (unreleased)
4
4
 
5
+ ## 1.4.0 (2022-01-24)
6
+
7
+ - Fixes [#55](https://github.com/palkan/influxer/issues/55) Rails 7 deprecation warning
8
+ - Add Ruby3 Support
9
+ - Updates InfluxDB client dependency
10
+ - Removes Ruby 2.4 supporting
11
+
12
+ ## 1.3.0 (2020-10-27)
13
+
14
+ - Fixes [#53](https://github.com/palkan/influxer/issues/53) Influxer client configuration issue with anyway config v2 and higher.([@AlexanderShvaykin][])
15
+
16
+ ## 1.2.2 (2020-10-27)
17
+
18
+ - Fixes [#49](https://github.com/palkan/influxer/issues/49) Cache hash configuration cannot be applied.([@AlexanderShvaykin][])
19
+ - Fixes [#47](https://github.com/palkan/influxer/issues/47) Can't delete data when retention policy is set for a metric. ([@MPursche][])
20
+
21
+ ## 1.2.1 (2020-07-09)
22
+
23
+ - Support for setting timezone in queries to configure influx time calculations, e.g., time epoch aggregation ([@jklimke][])
24
+
25
+ [PR](https://github.com/palkan/influxer/pull/46)
26
+
5
27
  ## 1.2.0 (2019-05-20)
6
28
 
7
29
  - **Require Ruby 2.4+**
@@ -24,11 +46,11 @@
24
46
 
25
47
  ## 1.1.4
26
48
 
27
- - [Fixes [#35](https://github.com/palkan/influxer/issues/35)] Support time duration suffix and handle `'s'` and `'ms'` precisions. ([@palkan][])
49
+ - [Fixes [#35](https://github.com/palkan/influxer/issues/35)] Support time duration suffix and handle `'s'` and `'ms'` precision. ([@palkan][])
28
50
 
29
51
  [PR](https://github.com/palkan/influxer/pull/36)
30
52
 
31
- **BREAKING:** `Time`-like value are only typecasted for `time` key.
53
+ **BREAKING:** `Time`-like value are only type-casted for `time` key.
32
54
 
33
55
  ## 1.1.2
34
56
 
@@ -78,56 +100,10 @@ end
78
100
 
79
101
  - Fix missing `#delegate` in ActiveRecord 3.2
80
102
 
81
- ## 0.5.4
82
- - Add `set_retention_policy` method
83
-
84
- ## 0.5.3
85
- - Fix `where.not` with ranges typo
86
-
87
- ## 0.5.2
88
- - Fix bug with query logging
89
-
90
- ## 0.5.1
91
- - Fix whitespace around operators
92
- - Add `Relation#from` method to redefine series
93
- - Handle nil values for tags in #where clause
94
-
95
- ## 0.5.0
96
- - Update `timestamp` support
97
- - Add `epoch` method
98
-
99
- ## 0.4.0
100
- - Rename default `time` attribute to `timestamp`
101
-
102
- ## 0.2.3
103
- - Parse fanout queries points to handle _fanouted_ values
104
- - Add Rubocop config and cleanup code style
105
-
106
- ## 0.1.1
107
- - Add [anyway_config](https://github.com/palkan/anyway_config)
108
- - Add `empty?` method
109
-
110
- ## 0.1.0
111
- - Add logs
112
- - Add `foreign_key` param to `has_metrics` options
113
-
114
- ## 0.1.0-rc
115
- - Fix `Relation#to_a` (now returns array of points correctrly)
116
- - Fix fanout queries with array args (now use `merge(Regexp)`)
117
-
118
- ## 0.1.0-alpha
119
- - Add `time` method to Relation to group by time with constants (`:hour`, `:day`, etc) and fill support
120
- - Series names now properly quoted with double-quotes
121
- - Using regexps, ranges and arrays within `where` clause
122
- - `where.not(...)` support
123
- - Add `past` and `since` methods
124
- - Add `merge` method and support for regexp series
125
- - Add `delete_all` support
126
- - Add cache support (using `Rails.cache`)
127
- - Scopes (default and named)
128
- - Support for fanout series
103
+ See [changelog](https://github.com/palkan/influxer/blob/1.0.0/Changelog.md) for earlier versions.
129
104
 
130
105
  [@palkan]: https://github.com/palkan
131
106
  [@MPursche]: https://github.com/MPursche
132
107
  [@jklimke]: https://github.com/jklimke
133
108
  [@dimiii]: https://github.com/dimiii
109
+ [@AlexanderShvaykin]: https://github.com/AlexanderShvaykin
@@ -1,4 +1,4 @@
1
- Copyright 2014-2019 palkan
1
+ Copyright 2014-2020 Vladimir Dementyev
2
2
 
3
3
  Permission is hereby granted, free of charge, to any person obtaining
4
4
  a copy of this software and associated documentation files (the
data/README.md CHANGED
@@ -1,37 +1,88 @@
1
- [![Gem Version](https://badge.fury.io/rb/influxer.svg)](https://rubygems.org/gems/influxer) [![Build Status](https://travis-ci.org/palkan/influxer.svg?branch=master)](https://travis-ci.org/palkan/influxer) [![Dependency Status](https://dependencyci.com/github/palkan/influxer/badge)](https://dependencyci.com/github/palkan/influxer)
2
- ## Influxer
1
+ ![Build](https://github.com/palkan/influxer/workflows/Build/badge.svg)
3
2
 
4
- **NOTE**: Version 0.3.x supports InfluxDB >= 0.9.0. For InfluxDB 0.8.x use [version 0.2.5](https://github.com/palkan/influxer/tree/0.2.5).
5
-
6
- **NOTE**: Influxer is Rails 4+ compatible! (Rails 3.2 support is still included but no longer required to pass all the tests).
3
+ # Influxer
7
4
 
8
5
  Influxer provides an ActiveRecord-style way to work with [InfluxDB](https://influxdb.com/) with many useful features, such as:
9
- - Familar query language (use `select`, `where`, `not`, `group` etc).
10
- - Support for Regex conditions: `where(page_id: /^home\/.*/) #=> select * ... where page_id=~/^home\/.*/`.
11
- - Special query methods for InfluxDB:
12
- - `time` - group by time (e.g. `Metrics.time(:hour) => # select * ... group by time(1h)`);
13
- - `past` - get only points for last hour/minute/whatever (e.g. `Metrics.past(:day) => # select * ... where time > now() - 1d`);
14
- - `since` - get only points since date (e.g. `Metrics.since(Time.utc(2014,12,31)) => # select * ... where time > 1419984000s`);
15
- - `merge` - merge series.
16
- - Scopes support
17
- ```ruby
6
+
7
+ ## Installation
8
+
9
+ Adding to a gem:
10
+
11
+ ```ruby
12
+ # my-cool-gem.gemspec
13
+ Gem::Specification.new do |spec|
14
+ # ...
15
+ spec.add_dependency "influxer", ">= 1.2.0"
16
+ # ...
17
+ end
18
+ ```
19
+
20
+ Or adding to your project:
21
+
22
+ ```ruby
23
+ # Gemfile
24
+ gem "influxer", "~> 1.2"
25
+ ```
26
+
27
+ ## Usage
28
+
29
+ ### Metrics classes
30
+
31
+ To query InfluxDB or write to it, you should define a metrics class first. Each metrics class represents a measurement/series (or multiple related measurements):
32
+
33
+ ```ruby
34
+ class VisitsMetrics < Influxer::Metrics
35
+ # Define tags...
36
+ tags :account_id, :page_id
37
+ # ...and attributes
38
+ attributes :user_id, :browser
39
+ end
40
+ ```
41
+
42
+ ### Querying
43
+
44
+ Now you can use your metrics classes in a similar way to Active Record models to build queries. For example:
45
+
46
+ ```ruby
47
+ VisitsMetrics.select(:account_id, :user_id).where(page_id: /^home\/.*/)
48
+ ```
49
+
50
+ Influxer provides special query methods for dealing with time series:
51
+
52
+ - Group by time: `Metrics.time(:hour) => # select * ... group by time(1h)`.
53
+ - Select only points for the last hour/minute/whatever: `Metrics.past(:day) => # select * ... where time > now() - 1d`.
54
+ - Select only points since the specified time: `Metrics.since(Time.utc(2014,12,31)) => # select * ... where time > 1419984000s`.
55
+ - and more.
56
+
57
+ See [our Wiki](https://github.com/palkan/influxer/wiki/Query-methods) for more.
58
+
59
+ ### Scopes support
60
+
61
+ You can define scopes to re-use query conditions:
62
+
63
+ ```ruby
18
64
  class Metrics < Influxer::Metrics
19
- default_scope -> { time(:hour).limit(1000) }
20
65
  tags :account_id
21
66
  attributes :value
67
+
68
+ default_scope -> { time(:hour).limit(1000) }
69
+
22
70
  scope :unlimited, -> { limit(nil) }
23
71
  scope :by_account, ->(id) { where(account_id: id) if id.present? }
24
72
  end
25
73
 
26
74
  Metrics.by_account(1)
27
- # => select * from "metrics" group by time(1h) where account_id=1 limit 1000
75
+ # => select * from "metrics" group by time(1h) where account_id=1 limit 1000
28
76
 
29
77
  Metrics.unlimited.by_account(1).time(:week)
30
- # => select * from "metrics" group by time(1w) where account_id=1
78
+ # => select * from "metrics" group by time(1w) where account_id=1
79
+ ```
80
+
81
+ ### Active Record integration
31
82
 
32
- ```
33
- - Integrate with your model:
34
- ```ruby
83
+ You can association metrics with Active Record models:
84
+
85
+ ```ruby
35
86
  class UserVisits < Influxer::Metrics
36
87
  end
37
88
 
@@ -41,10 +92,18 @@ end
41
92
 
42
93
  user = User.find(1)
43
94
  user.visits.write(page_id: "home")
44
- #=> < creates point {user_id: 1, page_id: 'home'} in 'user_visits' series >
95
+ #=> < creates point {user_id: 1, page_id: 'home'} in 'user_visits' series >
45
96
 
46
97
  user.visits.where(page_id: "home")
47
- #=> select * from user_visits where page_id='home'
48
- ```
98
+ #=> select * from user_visits where page_id='home'
99
+ ```
100
+
101
+ Find more on [Wiki](https://github.com/palkan/influxer/wiki/ActiveRecord-integration).
102
+
103
+ ## Contributing
104
+
105
+ Bug reports and pull requests are welcome on GitHub at [https://github.com/palkan/influxer](https://github.com/palkan/influxer).
106
+
107
+ ## License
49
108
 
50
- Find more on [Wiki](https://github.com/palkan/influxer/wiki).
109
+ The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
@@ -6,7 +6,7 @@ module Influxer
6
6
  # InfluxDB API client
7
7
  class Client < ::InfluxDB::Client
8
8
  def initialize
9
- super Influxer.config.as_json.symbolize_keys!
9
+ super(**Influxer.config.to_h.symbolize_keys)
10
10
  end
11
11
 
12
12
  def time_precision
@@ -28,15 +28,28 @@ module Influxer
28
28
  :denormalize,
29
29
  :udp,
30
30
  :async,
31
+ :cache_enabled,
32
+ :cache,
31
33
  database: "db",
32
34
  time_precision: "ns",
33
- cache: false,
34
35
  time_duration_suffix_enabled: false
35
36
 
36
37
  def load(*)
37
38
  super
38
- # we want pass @cache value as options to cache store, so we want it to be a Hash
39
- @cache = {}.with_indifferent_access if @cache == true
39
+ if cache_enabled.nil?
40
+ self.cache_enabled = cache_enabled_value
41
+ end
42
+ end
43
+
44
+ def cache=(value)
45
+ super
46
+ self.cache_enabled = cache_enabled_value
47
+ end
48
+
49
+ private
50
+
51
+ def cache_enabled_value
52
+ !!cache
40
53
  end
41
54
  end
42
55
  end
@@ -33,7 +33,7 @@ module Influxer
33
33
  [
34
34
  :write, :write!, :select, :where,
35
35
  :group, :time, :past, :since,
36
- :limit, :offset, :fill, :delete_all, :epoch
36
+ :limit, :offset, :fill, :delete_all, :epoch, :timezone
37
37
  ] + Influxer::Calculations::CALCULATION_METHODS
38
38
  ),
39
39
  to: :all
@@ -104,5 +104,11 @@ module Influxer
104
104
  @null_relation = !negate
105
105
  negate ? "time >= 0" : "time < 0"
106
106
  end
107
+
108
+ def where_contains_time?
109
+ where_values.any? do |where_clause|
110
+ /time( )/ === where_clause
111
+ end
112
+ end
107
113
  end
108
114
  end
@@ -22,11 +22,11 @@ module Influxer
22
22
 
23
23
  MULTI_KEY_METHODS = %i[fanout].freeze
24
24
 
25
- SINGLE_VALUE_METHODS = %i[fill time limit offset slimit soffset from normalized].freeze
25
+ SINGLE_VALUE_METHODS = %i[fill time limit offset slimit soffset from normalized timezone].freeze
26
26
 
27
27
  MULTI_VALUE_SIMPLE_METHODS = %i[select group].freeze
28
28
 
29
- SINGLE_VALUE_SIMPLE_METHODS = %i[fill limit offset slimit soffset from].freeze
29
+ SINGLE_VALUE_SIMPLE_METHODS = %i[fill limit offset slimit soffset from timezone].freeze
30
30
 
31
31
  MULTI_VALUE_METHODS.each do |name|
32
32
  class_eval <<-CODE, __FILE__, __LINE__ + 1
@@ -121,6 +121,13 @@ module Influxer
121
121
  self
122
122
  end
123
123
 
124
+ def timezone(val)
125
+ return self if val.blank?
126
+
127
+ @values[:timezone] = val
128
+ self
129
+ end
130
+
124
131
  def order(val)
125
132
  case val
126
133
  when Hash
@@ -159,6 +166,7 @@ module Influxer
159
166
  sql << "offset #{offset_value}" unless offset_value.nil?
160
167
  sql << "slimit #{slimit_value}" unless slimit_value.nil?
161
168
  sql << "soffset #{soffset_value}" unless soffset_value.nil?
169
+ sql << "TZ('#{timezone_value}')" unless timezone_value.blank?
162
170
  sql.join " "
163
171
  end
164
172
  # rubocop:enable Metrics/AbcSize
@@ -205,9 +213,13 @@ module Influxer
205
213
  end
206
214
 
207
215
  def delete_all
208
- sql = ["drop series"]
216
+ sql = if where_contains_time?
217
+ ["delete"]
218
+ else
219
+ ["drop series"]
220
+ end
209
221
 
210
- sql << "from #{@instance.series}"
222
+ sql << "from #{@instance.series(write: true)}"
211
223
 
212
224
  sql << "where #{where_values.join(" and ")}" unless where_values.empty?
213
225
 
@@ -1,6 +1,10 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- require "active_support/per_thread_registry"
3
+ if Influxer.thread_registry_support?
4
+ require "active_support/per_thread_registry"
5
+ else
6
+ require "active_support/core_ext/module/delegation"
7
+ end
4
8
 
5
9
  module Influxer
6
10
  module Scoping
@@ -15,7 +19,17 @@ module Influxer
15
19
  end
16
20
 
17
21
  class ScopeRegistry # :nodoc:
18
- extend ActiveSupport::PerThreadRegistry
22
+ if Influxer.thread_registry_support?
23
+ extend ActiveSupport::PerThreadRegistry
24
+ else
25
+ class << self
26
+ delegate :value_for, :set_value_for, to: :instance
27
+
28
+ def instance
29
+ ActiveSupport::IsolatedExecutionState[:influxer_scope_registry] ||= new
30
+ end
31
+ end
32
+ end
19
33
 
20
34
  VALID_SCOPE_TYPES = [:current_scope].freeze
21
35
 
@@ -6,10 +6,10 @@ module Influxer
6
6
  class Client
7
7
  def query(sql, options = {})
8
8
  log_sql(sql) do
9
- if !options.fetch(:cache, true) || Influxer.config.cache == false
10
- super(sql, options)
9
+ if !(options.fetch(:cache, true) && Influxer.config.cache_enabled)
10
+ super(sql, **options)
11
11
  else
12
- Rails.cache.fetch(normalized_cache_key(sql), cache_options(sql)) { super(sql, options) }
12
+ Rails.cache.fetch(normalized_cache_key(sql), **cache_options(sql)) { super(sql, **options) }
13
13
  end
14
14
  end
15
15
  end
@@ -33,8 +33,8 @@ module Influxer
33
33
  # of config.cache if defined
34
34
  def cache_options(sql = nil)
35
35
  options = Influxer.config.cache.dup
36
- options[:expires_in] = (options[:cache_now_for] || 60) if sql =~ /\snow\(\)/
37
- options
36
+ options[:expires_in] = (options[:cache_now_for] || 60) if /\snow\(\)/.match?(sql)
37
+ options.symbolize_keys
38
38
  end
39
39
 
40
40
  # add prefix; remove whitespaces
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Influxer # :nodoc:
4
- VERSION = "1.2.0"
4
+ VERSION = "1.4.0"
5
5
  end
data/lib/influxer.rb CHANGED
@@ -10,6 +10,10 @@ module Influxer
10
10
  ActiveModel::VERSION::MAJOR == 3
11
11
  end
12
12
 
13
+ def self.thread_registry_support?
14
+ ActiveModel::VERSION::MAJOR < 7
15
+ end
16
+
13
17
  require "influxer/config"
14
18
  require "influxer/client"
15
19
  require "influxer/metrics/metrics"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: influxer
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.0
4
+ version: 1.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Vlad Dem
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-05-21 00:00:00.000000000 Z
11
+ date: 2022-01-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activemodel
@@ -30,28 +30,28 @@ dependencies:
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: '0.3'
33
+ version: '0.8'
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: '0.3'
40
+ version: '0.8'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: anyway_config
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
45
  - - ">="
46
46
  - !ruby/object:Gem::Version
47
- version: '1.0'
47
+ version: '2.0'
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - ">="
53
53
  - !ruby/object:Gem::Version
54
- version: '1.0'
54
+ version: '2.0'
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: timecop
57
57
  requirement: !ruby/object:Gem::Requirement
@@ -143,21 +143,9 @@ executables: []
143
143
  extensions: []
144
144
  extra_rdoc_files: []
145
145
  files:
146
- - ".gitignore"
147
- - ".rspec"
148
- - ".rubocop.yml"
149
- - ".travis.yml"
150
- - Changelog.md
151
- - Gemfile
152
- - MIT-LICENSE
146
+ - CHANGELOG.md
147
+ - LICENSE.txt
153
148
  - README.md
154
- - Rakefile
155
- - bin/console
156
- - gemfiles/rails32.gemfile
157
- - gemfiles/rails42.gemfile
158
- - gemfiles/rails5.gemfile
159
- - gemfiles/rails6.gemfile
160
- - influxer.gemspec
161
149
  - lib/influxer.rb
162
150
  - lib/influxer/client.rb
163
151
  - lib/influxer/config.rb
@@ -177,24 +165,6 @@ files:
177
165
  - lib/influxer/model.rb
178
166
  - lib/influxer/rails/client.rb
179
167
  - lib/influxer/version.rb
180
- - spec/cases/points_spec.rb
181
- - spec/cases/write_points_spec.rb
182
- - spec/client_spec.rb
183
- - spec/fixtures/empty_result.json
184
- - spec/fixtures/single_series.json
185
- - spec/metrics/metrics_spec.rb
186
- - spec/metrics/relation_spec.rb
187
- - spec/metrics/scoping_spec.rb
188
- - spec/model/user_spec.rb
189
- - spec/spec_helper.rb
190
- - spec/support/metrics/action_metrics.rb
191
- - spec/support/metrics/custom_metrics.rb
192
- - spec/support/metrics/dummy_metrics.rb
193
- - spec/support/metrics/user_metrics.rb
194
- - spec/support/metrics/visits_metrics.rb
195
- - spec/support/shared_contexts/shared_precision.rb
196
- - spec/support/shared_contexts/shared_query.rb
197
- - spec/support/user.rb
198
168
  homepage: http://github.com/palkan/influxer
199
169
  licenses:
200
170
  - MIT
@@ -204,7 +174,7 @@ metadata:
204
174
  documentation_uri: http://github.com/palkan/influxer
205
175
  homepage_uri: http://github.com/palkan/influxer
206
176
  source_code_uri: http://github.com/palkan/influxer
207
- post_install_message:
177
+ post_install_message:
208
178
  rdoc_options: []
209
179
  require_paths:
210
180
  - lib
@@ -212,15 +182,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
212
182
  requirements:
213
183
  - - ">="
214
184
  - !ruby/object:Gem::Version
215
- version: 2.4.0
185
+ version: 2.5.0
216
186
  required_rubygems_version: !ruby/object:Gem::Requirement
217
187
  requirements:
218
188
  - - ">="
219
189
  - !ruby/object:Gem::Version
220
190
  version: '0'
221
191
  requirements: []
222
- rubygems_version: 3.0.3
223
- signing_key:
192
+ rubygems_version: 3.2.32
193
+ signing_key:
224
194
  specification_version: 4
225
195
  summary: InfluxDB for Rails
226
196
  test_files: []
data/.gitignore DELETED
@@ -1,37 +0,0 @@
1
- # Numerous always-ignore extensions
2
- *.diff
3
- *.err
4
- *.orig
5
- *.log
6
- *.rej
7
- *.swo
8
- *.swp
9
- *.vi
10
- *~
11
- *.sass-cache
12
- *.iml
13
- .idea/
14
-
15
- # Sublime
16
- *.sublime-project
17
- *.sublime-workspace
18
-
19
- # OS or Editor folders
20
- .DS_Store
21
- .cache
22
- .project
23
- .settings
24
- .tmproj
25
- Thumbs.db
26
-
27
- .bundle/
28
- log/*.log
29
- pkg/
30
- spec/dummy/db/*.sqlite3
31
- spec/dummy/db/*.sqlite3-journal
32
- spec/dummy/tmp/
33
- tmp/
34
-
35
- Gemfile.lock
36
- Gemfile.local
37
- *.gem
data/.rspec DELETED
@@ -1,2 +0,0 @@
1
- --color
2
- -f d
data/.rubocop.yml DELETED
@@ -1,57 +0,0 @@
1
- require:
2
- - standard/cop/semantic_blocks
3
- - rubocop-md
4
-
5
- inherit_gem:
6
- standard: config/base.yml
7
-
8
- AllCops:
9
- Exclude:
10
- - 'bin/*'
11
- - 'tmp/**/*'
12
- - 'docs/**/*'
13
- - 'Gemfile'
14
- - 'vendor/**/*'
15
- - 'gemfiles/**/*'
16
- DisplayCopNames: true
17
- TargetRubyVersion: 2.4
18
-
19
- Standard/SemanticBlocks:
20
- Enabled: false
21
-
22
- Style/FrozenStringLiteralComment:
23
- Enabled: true
24
-
25
- Naming/AccessorMethodName:
26
- Enabled: false
27
-
28
- Style/TrailingCommaInArrayLiteral:
29
- EnforcedStyleForMultiline: no_comma
30
-
31
- Style/TrailingCommaInHashLiteral:
32
- EnforcedStyleForMultiline: no_comma
33
-
34
- Layout/AlignParameters:
35
- EnforcedStyle: with_first_parameter
36
-
37
- Lint/Void:
38
- Exclude:
39
- - '**/*.md'
40
-
41
- # See https://github.com/rubocop-hq/rubocop/issues/4222
42
- Lint/AmbiguousBlockAssociation:
43
- Exclude:
44
- - 'spec/**/*'
45
- - '**/*.md'
46
-
47
- Lint/DuplicateMethods:
48
- Exclude:
49
- - '**/*.md'
50
-
51
- Naming/FileName:
52
- Exclude:
53
- - '**/*.md'
54
-
55
- Layout/InitialIndentation:
56
- Exclude:
57
- - 'CHANGELOG.md'