fluent-plugin-kafka-enchanced 0.5.34 → 0.5.35

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: 81789bef4b0d0bf1fceaa737dfb36776a8637320
4
- data.tar.gz: 37ee25e7657e0401b89618cb6e41945d0ffc380b
3
+ metadata.gz: 8bd3513dc92806cef3958e951ee968683c1d07df
4
+ data.tar.gz: 166872011022364bb0e14113ce8e9a9912121ff7
5
5
  SHA512:
6
- metadata.gz: d0cf89d417bae59d4be913752d8622ae500bd3c441335a7d1450f45a9b3d98960108e4a5461ff30ae12abfea8ef78ab82e842d76a65ac5c1ea15a4d6639af3fd
7
- data.tar.gz: da96168916bccd8d3bdce51cced7ca8b2049402a7e124c5132ba94ed46de187743510438c00abd9e54093f228cd155132765cc2c7d1d57de5fa15d74b28dcdfd
6
+ metadata.gz: e614c7edafc0a79c49b7fa4fb44ff74022e79c3d31281e6c13c1b1ec4cc69c36e2485b669caa4bc44a0f2005dff7957569eeb2e7488da7dea199aada25837058
7
+ data.tar.gz: 9d08ab481e936f6366b470d193f513ca2a2ac98f4f9ba4c782b4073bacf3e31a1789134950b7f99176b7c3d861e69215bac80d98ddbc8faaadc92e71e9cc4833
@@ -12,7 +12,7 @@ Gem::Specification.new do |gem|
12
12
  gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
13
13
  gem.name = "fluent-plugin-kafka-enchanced"
14
14
  gem.require_paths = ["lib"]
15
- gem.version = '0.5.34'
15
+ gem.version = '0.5.35'
16
16
  gem.required_ruby_version = ">= 2.1.0"
17
17
 
18
18
  gem.add_dependency "fluentd", [">= 0.10.58", "< 2"]
@@ -155,8 +155,6 @@ DESC
155
155
  (v.is_a?(Fixnum) || v.is_a?(Float) || v.nil? ? v : v.to_s.force_encoding("UTF-8"))
156
156
  ]
157
157
  end.to_h
158
- timestamp = Time.new
159
- record['enchilada_time_with_format'] = timestamp.strftime("%Y-%m-%dT%H:%M:%S.%LZ")
160
158
  @topic_name = schema_name = "#{tag.to_s.tr('.$:', '_')}_#{Digest::MD5.new.hexdigest(record.keys.to_s)[0..5]}"
161
159
 
162
160
  avro = AvroTurf::Messaging.new(registry_url: @schema_registry)
@@ -170,6 +168,7 @@ DESC
170
168
  end
171
169
  field_types = fields.map{|field| [field['name'], (field['type'] - ['null']).first]}.to_h
172
170
  fields << {"name" => "enchilada_timestamp", "type" => "long"}
171
+ fields << {"name" => "enchilada_time_with_format", "type" => "string"}
173
172
  schema_json = {
174
173
  "type": "record",
175
174
  "name": schema_name,
@@ -189,7 +188,9 @@ DESC
189
188
  set_schema_to_redis(schema_name, stored_schema)
190
189
  end
191
190
 
191
+ timestamp = Time.new
192
192
  record['enchilada_timestamp'] = timestamp.strftime('%s%3N').to_i
193
+ record['enchilada_time_with_format'] = timestamp.strftime("%Y-%m-%dT%H:%M:%S.%LZ")
193
194
  record = record.map do |key, val|
194
195
  [key, (stored_schema['field_types'][key] != 'string' || val.nil? ? val : val.to_s)]
195
196
  end.to_h
@@ -208,8 +208,6 @@ DESC
208
208
  (v.is_a?(Fixnum) || v.is_a?(Float) || v.nil? ? v : v.to_s.force_encoding("UTF-8"))
209
209
  ]
210
210
  end.to_h
211
- timestamp = Time.new
212
- record['enchilada_time_with_format'] = timestamp.strftime("%Y-%m-%dT%H:%M:%S.%LZ")
213
211
  @topic_name = schema_name = "#{tag.to_s.tr('.$:', '_')}_#{Digest::MD5.new.hexdigest(record.keys.to_s)[0..5]}"
214
212
 
215
213
  avro = AvroTurf::Messaging.new(registry_url: @schema_registry)
@@ -223,6 +221,7 @@ DESC
223
221
  end
224
222
  field_types = fields.map{|field| [field['name'], (field['type'] - ['null']).first]}.to_h
225
223
  fields << {"name" => "enchilada_timestamp", "type" => "long"}
224
+ fields << {"name" => "enchilada_time_with_format", "type" => "string"}
226
225
  schema_json = {
227
226
  "type": "record",
228
227
  "name": schema_name,
@@ -243,6 +242,8 @@ DESC
243
242
 
244
243
  end
245
244
 
245
+ timestamp = Time.new
246
+ record['enchilada_time_with_format'] = timestamp.strftime("%Y-%m-%dT%H:%M:%S.%LZ")
246
247
  record['enchilada_timestamp'] = timestamp.strftime('%s%3N').to_i
247
248
  record = record.map do |key, val|
248
249
  [key, (stored_schema['field_types'][key] != 'string' || val.nil? ? val : val.to_s)]
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fluent-plugin-kafka-enchanced
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.34
4
+ version: 0.5.35
5
5
  platform: ruby
6
6
  authors:
7
7
  - Paschenko Konstantin
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-03-30 00:00:00.000000000 Z
11
+ date: 2017-03-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: fluentd