fluent-plugin-json-in-json 0.1.2 → 0.1.3

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: 516f10d88898ff297402ec12ce5fcd3194e19851
4
- data.tar.gz: 04a51da2be344471238e10065d6fbb5bf261ba97
3
+ metadata.gz: 868c883a280025a4d5ac0260b062e12f48b2c3d4
4
+ data.tar.gz: 7f6a866ed648c2eca97d265bec148c8a11660040
5
5
  SHA512:
6
- metadata.gz: 84010a6713575b8a24ad19ed8499e36d77334bd4eecf435121b25e75575926e5fac08f793671d99c152d93d4372d01e360f705ddaa69949490efbe959988656e
7
- data.tar.gz: 6793e3a089f3ec0c936d8290eac34ec82d22400aa6918202d899490db72c155c589f87fe21fa0914bf5e35f08f713be4a975084fdff4b8ff322c9a98be3f8138
6
+ metadata.gz: 5aecc10aa4d2f649a22b2d6166f2eb8bb1ebbd151503b6ed7fa71c6e6f1607d87d3081e9bb5f3d85220c214cc0ee63099c1892ab0d9a9da9ecc4a839d315708b
7
+ data.tar.gz: 18ba0722a89c88ad0a1be633721bfcbed9acfaf8ee8efa4f4c93f9b154055879076b73dfbe376d8cd4e0182fa3c29da11cc301f34b1049e42cbba4a96cbcf25a
@@ -1,7 +1,7 @@
1
1
  # coding: utf-8
2
2
  Gem::Specification.new do |spec|
3
3
  spec.name = "fluent-plugin-json-in-json"
4
- spec.version = "0.1.2"
4
+ spec.version = "0.1.3"
5
5
  spec.authors = ["Gavin M. Roy"]
6
6
  spec.email = ["gavinmroy@gmail.com"]
7
7
  spec.description = %q{Parser plugin that parses JSON attributes with JSON strings in them}
@@ -39,6 +39,15 @@ module Fluent
39
39
  end
40
40
  end
41
41
 
42
+ record.each do |k, v|
43
+ if v[0] == '{' and v[-1] == '}'
44
+ h = Yajl.load(v)
45
+ h.each do |vk, vv|
46
+ record[vk] = vv
47
+ end
48
+ end
49
+ end
50
+
42
51
  if block_given?
43
52
  yield time, record
44
53
  else
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fluent-plugin-json-in-json
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gavin M. Roy