fluent-plugin-text_to_json 0.1.5 → 0.1.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/fluent/plugin/formatter_text_to_json.rb +1 -3
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e1c9d87f49911ea10034dfc1f5096b535fdc92e6
|
4
|
+
data.tar.gz: e5c06e89318a287643d558605655380c2b567694
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e44d5b88b5f48f97c6185b94e538b89560a597015685c924f456a117464c02fe3a33b7877cdb6084d0d3ff712ad033d21d6980f2ce5347188ef7a382f257650c
|
7
|
+
data.tar.gz: 74057d6c6dd399f87a27e65b082b0ad86873024f03d497721ce6541bae9af676c3627838d81df34b8d99bacd88813e38343dbef7440b3ff5ac2ea8abbb2524a8
|
@@ -1,7 +1,6 @@
|
|
1
1
|
require "fluent/formatter"
|
2
2
|
|
3
3
|
module Fluent
|
4
|
-
module TextFormatter
|
5
4
|
class TextToJsonFormatter < Formatter
|
6
5
|
Plugin.register_formatter('text_to_json', self)
|
7
6
|
|
@@ -13,7 +12,7 @@ module Fluent
|
|
13
12
|
@fields = @json_field.split(",").map{|field| "\"" + field + "\""}
|
14
13
|
end
|
15
14
|
|
16
|
-
def format(
|
15
|
+
def format(record)
|
17
16
|
tmp_field = Array.new
|
18
17
|
tmp_field = record.split(@field_splitter)
|
19
18
|
|
@@ -53,5 +52,4 @@ module Fluent
|
|
53
52
|
|
54
53
|
end
|
55
54
|
end
|
56
|
-
end
|
57
55
|
end
|