influxdb 0.3.16 → 0.3.17

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 6220099c5c1aaa4926acf2b73f6344110a026e2e
4
- data.tar.gz: df99c2b82e703cc60fc8a9b9eb9805344ccf2a9d
3
+ metadata.gz: 6340af963bab464fd867383a9cc807e05595df17
4
+ data.tar.gz: 4e6de52c3d235ea4ecef32ec208cd37bf713452f
5
5
  SHA512:
6
- metadata.gz: 31e1a5b07ae57d4687f08c021ac5919320e54ba3ff3efed9008b906621a3d7fa5ac3a17a3a4d1943707cf426d0e9935b3b47a9395f611d6c0df21658c588470f
7
- data.tar.gz: 266143d2bd9ce9eabab785209511619b1f92eb26efe7c374cd26ddd71083f349296f8719f354268906329bfca7f60d09e19ce68badf05ef4f0e4f45167e6a6d3
6
+ metadata.gz: 75666cbccc4d308b0eb75608047041095f78158201c6e9e994bfd41e8e3450826b94f759f56f65f526d042befa73ceb9c0db443aa4d2925f72828fbee8c928b5
7
+ data.tar.gz: e0665e344e62644e9e53534eefb9ff26530e7d7aaaf121edd321c5f070bba0aa9894c02b38a8ce28d24b444e475a7860c13c25a90653600f126b050011c64364
@@ -10,9 +10,9 @@ rvm:
10
10
  - 1.9.3
11
11
  - 2.0.0
12
12
  - 2.1.10
13
- - 2.2.5
14
- - 2.3.3
15
- - 2.4.0
13
+ - 2.2.7
14
+ - 2.3.5
15
+ - 2.4.2
16
16
  - ruby-head
17
17
  env:
18
18
  - TEST_TASK=spec
@@ -22,23 +22,23 @@ matrix:
22
22
  - rvm: jruby-head
23
23
  - rvm: ruby-head
24
24
  - rvm: jruby-9.1.5.0
25
- - rvm: 2.4.0
25
+ - rvm: 2.4.2
26
26
  env: TEST_TASK=smoke influx_version=nightly channel=nightlies
27
27
  include:
28
- - rvm: 2.4.0
28
+ - rvm: 2.4.2
29
29
  env: TEST_TASK=rubocop
30
30
  - rvm: jruby-9.1.5.0
31
31
  - rvm: jruby-head
32
32
  env: JRUBY_OPTS='--client -J-XX:+TieredCompilation -J-XX:TieredStopAtLevel=1 -J-Xss2m -J-Xmx256M'
33
- - rvm: 2.4.0
33
+ - rvm: 2.4.2
34
34
  env: TEST_TASK=smoke influx_version=1.0.2 pkghash=3e4c349cb57507913d9abda1459bdbed
35
- - rvm: 2.4.0
35
+ - rvm: 2.4.2
36
36
  env: TEST_TASK=smoke influx_version=1.1.0 pkghash=682904c350ecfc2a60ec9c6c08453ef2
37
- - rvm: 2.4.0
37
+ - rvm: 2.4.2
38
38
  env: TEST_TASK=smoke influx_version=1.2.4 pkghash=0545d67217393282188e5d5cdedfdc85
39
- - rvm: 2.4.0
40
- env: TEST_TASK=smoke influx_version=1.3.2 pkghash=27b200344bed9de9df193b62a59d378f
41
- - rvm: 2.4.0
39
+ - rvm: 2.4.2
40
+ env: TEST_TASK=smoke influx_version=1.3.5 pkghash=479c63bbb66561c302aff2d9bf639bf3
41
+ - rvm: 2.4.2
42
42
  env: TEST_TASK=smoke influx_version=nightly channel=nightlies
43
43
  fail_fast: true
44
44
  addons:
@@ -6,6 +6,13 @@ For the full commit log, [see here](https://github.com/influxdata/influxdb-ruby/
6
6
 
7
7
  - nothing yet
8
8
 
9
+ ## v0.3.17, released 2017-09-27
10
+
11
+ - (Backport from v0.4.1) Bugfix in async client: Flush queue before exit
12
+ (#198, #199 @onlynone)
13
+ - (Backport from v0.4.2) Bugfix in `InfluxDB::PointValue`: Properly
14
+ encode backslashes (#200)
15
+
9
16
  ## v0.3.16, released 2017-08-17
10
17
 
11
18
  - **This is propably the last release in the 0.3.x series**
@@ -56,11 +56,16 @@ module InfluxDB
56
56
  @stopped = false
57
57
  @writer = find_writer
58
58
 
59
- at_exit { stop! } if config.retry > 0
59
+ at_exit { stop! }
60
60
  end
61
61
 
62
62
  def stop!
63
- writer.worker.stop! if config.async?
63
+ if config.async?
64
+ # If retry was infinite (-1), set it to zero to give the main thread one
65
+ # last chance to flush the queue
66
+ config.retry = 0 if config.retry < 0
67
+ writer.worker.stop!
68
+ end
64
69
  @stopped = true
65
70
  end
66
71
 
@@ -25,7 +25,7 @@ module InfluxDB
25
25
  tag_key: ['='.freeze, ' '.freeze, ','.freeze],
26
26
  tag_value: ['='.freeze, ' '.freeze, ','.freeze],
27
27
  field_key: ['='.freeze, ' '.freeze, ','.freeze, '"'.freeze],
28
- field_value: ['"'.freeze],
28
+ field_value: ["\\".freeze, '"'.freeze],
29
29
  }.freeze
30
30
 
31
31
  def escape(s, type)
@@ -1,3 +1,3 @@
1
1
  module InfluxDB # :nodoc:
2
- VERSION = "0.3.16".freeze
2
+ VERSION = "0.3.17".freeze
3
3
  end
@@ -15,7 +15,8 @@ describe InfluxDB::PointValue do
15
15
  intval: 5,
16
16
  floatval: 7.0,
17
17
  invalid_encoding: "a b",
18
- non_latin: "Улан-Удэ"
18
+ non_latin: "Улан-Удэ",
19
+ backslash: "C:\\", # issue #200
19
20
  }
20
21
  }
21
22
  if RUBY_VERSION > "2.0.0"
@@ -27,8 +28,20 @@ describe InfluxDB::PointValue do
27
28
 
28
29
  it 'should escape correctly' do
29
30
  point = InfluxDB::PointValue.new(data)
30
- expected = %(1=\\ \\,"\\1,2\\=\\ \\,"\\2=3\\=\\ \\,"\\3 ) +
31
- %(4\\=\\ \\,\\"\\4="5= ,\\"\\5",intval=5i,floatval=7.0,invalid_encoding="a b",non_latin="Улан-Удэ")
31
+ series = [
32
+ %(1=\\ \\,"\\1),
33
+ %(2\\=\\ \\,"\\2=3\\=\\ \\,"\\3),
34
+ ]
35
+ fields = [
36
+ %(4\\=\\ \\,\\"\\4="5= ,\\"\\\\5"),
37
+ %(intval=5i),
38
+ %(floatval=7.0),
39
+ %(invalid_encoding="a b"),
40
+ %(non_latin="Улан-Удэ"),
41
+ %(backslash="C:\\\\"),
42
+ ]
43
+
44
+ expected = series.join(",") + " " + fields.join(",")
32
45
  expect(point.dump).to eq(expected)
33
46
  end
34
47
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: influxdb
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.16
4
+ version: 0.3.17
5
5
  platform: ruby
6
6
  authors:
7
7
  - Todd Persen
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-08-17 00:00:00.000000000 Z
11
+ date: 2017-09-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: json