influxer 1.3.0 → 2.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +17 -3
- data/README.md +1 -1
- data/lib/influxer/client.rb +1 -1
- data/lib/influxer/metrics/relation/where_clause.rb +8 -2
- data/lib/influxer/metrics/relation.rb +1 -1
- data/lib/influxer/metrics/scoping/current_scope.rb +16 -2
- data/lib/influxer/version.rb +1 -1
- data/lib/influxer.rb +4 -0
- metadata +8 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e062c5d510539a73a1a169d070788871bbb719772004d3f05cac981df10b0ddc
|
4
|
+
data.tar.gz: 7c4b85a4a15d231296f43fcfcd9465d31f9269ac5dd68ca8630a398f5da8adff
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 43d7fc198d93b1fae12d413e9730a1cbdca778bb14e35bde6f3b1e2e84741f6ed416e08108f87a9c3cb1a7a8e65c5e281d54ff7bb3f4f4a155e8182d2998d71d
|
7
|
+
data.tar.gz: 66e78510434faa751a8f2c68c74d610d2686b2957bb6cd303d0561d51fdf87dbd379f34c0eea7771a3293c473f517ffb5543b6635c2a1aeb47cdb9bcaa564505
|
data/CHANGELOG.md
CHANGED
@@ -2,13 +2,27 @@
|
|
2
2
|
|
3
3
|
## master (unreleased)
|
4
4
|
|
5
|
+
## 2.0.0 (2024-10-12)
|
6
|
+
|
7
|
+
- Upgraded Ruby and Rails version to Ruby 2.7.6 and Rails 6
|
8
|
+
- Added support for providing hash objects as arguments to where condition in ruby >= 3
|
9
|
+
- Removes support for Rails 5
|
10
|
+
- Removes support for Ruby less than 2.7
|
11
|
+
|
12
|
+
## 1.4.0 (2022-01-24)
|
13
|
+
|
14
|
+
- Fixes [#55](https://github.com/palkan/influxer/issues/55) Rails 7 deprecation warning
|
15
|
+
- Add Ruby3 Support
|
16
|
+
- Updates InfluxDB client dependency
|
17
|
+
- Removes Ruby 2.4 supporting
|
18
|
+
|
5
19
|
## 1.3.0 (2020-10-27)
|
6
20
|
|
7
21
|
- Fixes [#53](https://github.com/palkan/influxer/issues/53) Influxer client configuration issue with anyway config v2 and higher.([@AlexanderShvaykin][])
|
8
22
|
|
9
23
|
## 1.2.2 (2020-10-27)
|
10
24
|
|
11
|
-
- Fixes [#49](https://github.com/palkan/influxer/issues/49)
|
25
|
+
- Fixes [#49](https://github.com/palkan/influxer/issues/49) Cache hash configuration cannot be applied.([@AlexanderShvaykin][])
|
12
26
|
- Fixes [#47](https://github.com/palkan/influxer/issues/47) Can't delete data when retention policy is set for a metric. ([@MPursche][])
|
13
27
|
|
14
28
|
## 1.2.1 (2020-07-09)
|
@@ -96,7 +110,7 @@ end
|
|
96
110
|
See [changelog](https://github.com/palkan/influxer/blob/1.0.0/Changelog.md) for earlier versions.
|
97
111
|
|
98
112
|
[@palkan]: https://github.com/palkan
|
99
|
-
[@
|
113
|
+
[@mpursche]: https://github.com/MPursche
|
100
114
|
[@jklimke]: https://github.com/jklimke
|
101
115
|
[@dimiii]: https://github.com/dimiii
|
102
|
-
[@
|
116
|
+
[@alexandershvaykin]: https://github.com/AlexanderShvaykin
|
data/README.md
CHANGED
data/lib/influxer/client.rb
CHANGED
@@ -36,8 +36,14 @@ module Influxer
|
|
36
36
|
protected
|
37
37
|
|
38
38
|
def build_where(args, hargs, negate)
|
39
|
-
if args.present?
|
40
|
-
|
39
|
+
if args.present?
|
40
|
+
if args[0].is_a?(String)
|
41
|
+
where_values.concat(args.map { |str| "(#{str})" })
|
42
|
+
elsif args[0].is_a?(Hash)
|
43
|
+
build_hash_where(args[0], negate)
|
44
|
+
else
|
45
|
+
false
|
46
|
+
end
|
41
47
|
elsif hargs.present?
|
42
48
|
build_hash_where(hargs, negate)
|
43
49
|
else
|
@@ -1,6 +1,10 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
|
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
|
-
|
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
|
|
data/lib/influxer/version.rb
CHANGED
data/lib/influxer.rb
CHANGED
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:
|
4
|
+
version: 2.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Vlad Dem
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2024-10-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activemodel
|
@@ -16,28 +16,28 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version:
|
19
|
+
version: '6.0'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - ">="
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version:
|
26
|
+
version: '6.0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: influxdb
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
31
|
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: '0.
|
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.
|
40
|
+
version: '0.8'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: anyway_config
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -182,14 +182,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
182
182
|
requirements:
|
183
183
|
- - ">="
|
184
184
|
- !ruby/object:Gem::Version
|
185
|
-
version: 2.
|
185
|
+
version: 2.7.6
|
186
186
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
187
187
|
requirements:
|
188
188
|
- - ">="
|
189
189
|
- !ruby/object:Gem::Version
|
190
190
|
version: '0'
|
191
191
|
requirements: []
|
192
|
-
rubygems_version: 3.
|
192
|
+
rubygems_version: 3.3.7
|
193
193
|
signing_key:
|
194
194
|
specification_version: 4
|
195
195
|
summary: InfluxDB for Rails
|