fluent-logger 0.7.1 → 0.7.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 138aa1f6b2e893e052fa4aab33e38ffe50a001da
4
- data.tar.gz: d6fb45180e4d79317df370ffd14ef8acb659ffab
3
+ metadata.gz: 534a2ccb4ce18b0c8082c309d464d6291ede39f5
4
+ data.tar.gz: d57458f299eccdff242de08e5d6ea03d2cee4ed3
5
5
  SHA512:
6
- metadata.gz: 4b402b52625c8f1676eaece98d86e5aad61fda1d05c0623f926caf9074afdf589efca44851aefdead592212addc4124874ea27903f3861b867ca7336f65f5f47
7
- data.tar.gz: 921a3538d1e758502cf9986d2857c5f41e676c5dc5af6a72c57ac08d29e4889c0dbc9e786ef0d855230a29a965efcc0654c1c7e85da0fcbfa71d847c9ab76124
6
+ metadata.gz: e5f6dc505d218591c81b5945f894aef62551610a404f8ce6e68b88f5bed88165b9a931a22cd99e3f02180575b0d6d367d617dcd287d544914eecbcf03b349b3f
7
+ data.tar.gz: 3e4f91caab8f1d472709611867dbe6e3ade664d0fe954123f08e193a18922e359bb7ca3665f04d552ba7432db2802dd1dd322d7cfcc3bcbda49c83724d19109a
data/ChangeLog CHANGED
@@ -1,3 +1,7 @@
1
+ Release 0.7.2 - 2018/01/04
2
+
3
+ * Fix EventTime for nanosecond_precision
4
+
1
5
  Release 0.7.1 - 2017/04/19
2
6
 
3
7
  * Fix packer clear bug for non-msgpackable data
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.7.1
1
+ 0.7.2
@@ -7,11 +7,9 @@ Gem::Specification.new do |gem|
7
7
  File.open(version_file, "w") {|f|
8
8
  f.write <<EOF
9
9
  module Fluent
10
- module Logger
11
-
12
- VERSION = '#{version}'
13
-
14
- end
10
+ module Logger
11
+ VERSION = '#{version}'
12
+ end
15
13
  end
16
14
  EOF
17
15
  }
@@ -26,16 +26,17 @@ module Fluent
26
26
  class EventTime
27
27
  TYPE = 0
28
28
 
29
- def initialize(raw_time)
30
- @time = raw_time
29
+ def initialize(sec, nsec = 0)
30
+ @sec = sec
31
+ @nsec = nsec
31
32
  end
32
33
 
33
34
  def to_msgpack(io = nil)
34
- @time.to_i.to_msgpack(io)
35
+ @sec.to_msgpack(io)
35
36
  end
36
37
 
37
38
  def to_msgpack_ext
38
- [@time.to_i, @time.nsec].pack('NN')
39
+ [@sec, @nsec].pack('NN')
39
40
  end
40
41
 
41
42
  def self.from_msgpack_ext(data)
@@ -43,7 +44,7 @@ module Fluent
43
44
  end
44
45
 
45
46
  def to_json(*args)
46
- @time.to_i
47
+ @sec
47
48
  end
48
49
  end
49
50
 
@@ -130,7 +131,7 @@ module Fluent
130
131
  @logger.debug { "event: #{tag} #{map.to_json}" rescue nil } if @logger.debug?
131
132
  tag = "#{@tag_prefix}.#{tag}" if @tag_prefix
132
133
  if @nanosecond_precision && time.is_a?(Time)
133
- write [tag, EventTime.new(time), map]
134
+ write [tag, EventTime.new(time.to_i, time.nsec), map]
134
135
  else
135
136
  write [tag, time.to_i, map]
136
137
  end
@@ -1,7 +1,5 @@
1
1
  module Fluent
2
- module Logger
3
-
4
- VERSION = '0.7.1'
5
-
6
- end
2
+ module Logger
3
+ VERSION = '0.7.2'
4
+ end
7
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fluent-logger
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.1
4
+ version: 0.7.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sadayuki Furuhashi
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-04-18 00:00:00.000000000 Z
11
+ date: 2018-01-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: msgpack
@@ -162,7 +162,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
162
162
  version: '0'
163
163
  requirements: []
164
164
  rubyforge_project:
165
- rubygems_version: 2.6.11
165
+ rubygems_version: 2.6.13
166
166
  signing_key:
167
167
  specification_version: 4
168
168
  summary: fluent logger for ruby