franz 1.6.4 → 1.6.5

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: fd7ded091e8791fdf52b423e2a66895e48dfd0f3
4
- data.tar.gz: 5aca71dcd6052cbb2a147884b86de8141c505664
3
+ metadata.gz: 15ec73cb6037c16c59a295c5d1e17160edfcff2b
4
+ data.tar.gz: 0e68faaa4df6f3d52d4f563c288aeca74b7cb72c
5
5
  SHA512:
6
- metadata.gz: 4f51b1de2cac2128ee0bac0cc728ba08657c773a52965083e6c88d2dca9e5ebffac09276484c863c1d1bfdd993982b605ea9135d252dd17be648038df75e7ebe
7
- data.tar.gz: 7ef909db8aca7ce60a1fde825d86f8113bbd1d3fdcf7a3454ace72fed0baadff0522b7637aab72e658eb7ac00a1cc03f25a3a3c8006df43fbdf2fdd1a1317ce8
6
+ metadata.gz: 7d4156f5ace594a8d7ed5846efe1d05f1b2eb23c38038bd526516dc9b351e6e4fe3bfcc2e90a79f6f36ef6b67625c51531ecf8dc359eb542a9d8995f21206794
7
+ data.tar.gz: 884ff2d8cae0b911310efb98d1203d2b28685c1b15c8f7e756c96deeade3ac41079a8c75bdc2b59c3880e9f529b072fb1c8ec66852a746f0e82b48b95506ef2c
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.6.4
1
+ 1.6.5
data/lib/franz/agg.rb CHANGED
@@ -92,7 +92,7 @@ module Franz
92
92
  if @ic.drop? path, message
93
93
  log.trace \
94
94
  event: 'dropped',
95
- path: path,
95
+ file: path,
96
96
  message: message
97
97
  return
98
98
  end
@@ -101,25 +101,25 @@ module Franz
101
101
  if t.nil?
102
102
  log.trace \
103
103
  event: 'enqueue skipped',
104
- path: path,
104
+ file: path,
105
105
  message: message
106
106
  return
107
107
  end
108
108
 
109
109
  log.trace \
110
110
  event: 'enqueue',
111
- path: path,
111
+ file: path,
112
112
  message: message
113
113
  s = seq path
114
114
  m = message.encode 'UTF-8', invalid: :replace, undef: :replace, replace: '?'
115
115
 
116
- event = { type: t, host: @@host, '@seq' => s }
116
+ event = { type: t, host: @@host, path: path, '@seq' => s }
117
117
 
118
118
  if @ic.json? path
119
119
  return if m =~ /^#/
120
- event = JSON::parse(m).merge(event)
120
+ event.merge! JSON::parse(m)
121
121
  else
122
- event.merge! message: m, path: path
122
+ event.merge! message: m
123
123
  end
124
124
  agg_events.push event
125
125
  end
@@ -139,7 +139,7 @@ module Franz
139
139
  if size > @buffer_limit
140
140
  log.trace \
141
141
  event: 'buffer overflow',
142
- path: event[:path],
142
+ file: event[:path],
143
143
  size: size,
144
144
  limmit: @buffer_limit
145
145
  end
@@ -51,7 +51,7 @@ class Franz::Discover
51
51
  @statz.inc :num_deleted
52
52
  log.debug \
53
53
  event: 'discover deleted',
54
- path: d
54
+ file: d
55
55
  end
56
56
 
57
57
  discover.each do |discovery|
@@ -60,7 +60,7 @@ class Franz::Discover
60
60
  @statz.inc :num_discovered
61
61
  log.debug \
62
62
  event: 'discover discovered',
63
- path: discovery
63
+ file: discovery
64
64
  end
65
65
  sleep discover_interval
66
66
  end
@@ -55,7 +55,7 @@ module Franz
55
55
  end
56
56
  log.warn \
57
57
  event: 'type unknown',
58
- path: path
58
+ file: path
59
59
  @types[path] = nil
60
60
  return nil
61
61
  end
data/lib/franz/tail.rb CHANGED
@@ -79,7 +79,7 @@ module Franz
79
79
  def read path, size
80
80
  log.trace \
81
81
  event: 'read',
82
- path: path,
82
+ file: path,
83
83
  size: size
84
84
  @cursors[path] ||= 0
85
85
  spread = size - @cursors[path]
@@ -92,7 +92,7 @@ module Franz
92
92
  if spread.abs > @block_size
93
93
  log.warn \
94
94
  event: 'large spread',
95
- path: path,
95
+ file: path,
96
96
  size: size,
97
97
  cursor: @cursors[path],
98
98
  spread: spread
@@ -103,7 +103,7 @@ module Franz
103
103
  if spread > @read_limit
104
104
  log.warn \
105
105
  event: 'large read',
106
- path: path,
106
+ file: path,
107
107
  size: size,
108
108
  cursor: @cursors[path],
109
109
  spread: spread
@@ -129,7 +129,7 @@ module Franz
129
129
  # :rotated, :deleted event comes along soon after. If it doesn't...
130
130
  log.error \
131
131
  event: 'nil read',
132
- path: path,
132
+ file: path,
133
133
  size: size,
134
134
  cursor: @cursors[path],
135
135
  spread: (size - @cursors[path]),
@@ -147,7 +147,7 @@ module Franz
147
147
  rescue RuntimeError
148
148
  log.fatal \
149
149
  event: 'buffer full',
150
- path: path,
150
+ file: path,
151
151
  size: size,
152
152
  cursor: @cursors[path],
153
153
  spread: (size - @cursors[path])
@@ -160,7 +160,7 @@ module Franz
160
160
  if @cursors[path] < size
161
161
  log.fatal \
162
162
  event: 'incomplete read',
163
- path: path,
163
+ file: path,
164
164
  size: size,
165
165
  cursor: @cursors[path],
166
166
  spread: (size - @cursors[path])
@@ -170,7 +170,7 @@ module Franz
170
170
 
171
171
 
172
172
  def close path
173
- log.trace event: 'close', path: path
173
+ log.trace event: 'close', file: path
174
174
  tail_events.push path: path, line: buffer[path].flush
175
175
  @nil_read.delete path
176
176
  @cursors[path] = 0
data/lib/franz/watch.rb CHANGED
@@ -94,7 +94,7 @@ module Franz
94
94
  log.trace \
95
95
  event: 'enqueue',
96
96
  name: name,
97
- path: path,
97
+ file: path,
98
98
  size: size
99
99
  watch_events.push name: name, path: path, size: size
100
100
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: franz
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.4
4
+ version: 1.6.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sean Clemmer
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-01-25 00:00:00.000000000 Z
11
+ date: 2015-01-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: slog