fluent-plugin-nais 0.6.0 → 0.7.0

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: 9184b29be4d881feb794571592ed6d08bf6dbd3c
4
- data.tar.gz: 1022a8909b6db539c76605c68880eb9dec44e421
3
+ metadata.gz: fdc6303b9eb6eefde308f091e45194b3b2eeb1e4
4
+ data.tar.gz: 0e0e558eba6e98ecff6367cf9ce8eac9168b2113
5
5
  SHA512:
6
- metadata.gz: e946168faae6579b76bce2bb8fd56b0e7821c7461e1f643ae84ca2c542f506f1ebf7f569e44dca83caa1d1fcdf83660c934da62bd9feb570c6cb4c84cbc79990
7
- data.tar.gz: 4dc3e1a6fe75c2b140789fb620166d0a55f2651e4e490e0bd12a68293caae7250911b4960941c73b0474a394376c26725cd7aa73998baae75e73d33ff79af6b6
6
+ metadata.gz: 731eb4c5bd836731ff10064af1f2cf77ac77f533d93fa3c782655a661786afe7c43cfbdf45e61d18356b5d0421d0617cdf7fd41e73c3a3d8440560b3cf2472e3
7
+ data.tar.gz: f4e5664b02a751f441925ae3f308ecb5c4eb6e1fb764ba835e9b932981b2215f5996aca77d8beb2c4b447fd97623a27fe8f49e3c601929b58bed65af98769651
@@ -21,7 +21,7 @@ Gem::Specification.new do |spec|
21
21
  spec.require_paths = ["lib"]
22
22
 
23
23
  spec.add_dependency 'fluentd', '~> 0.14'
24
- spec.add_dependency 'nais-log-parser', '~> 0.9'
24
+ spec.add_dependency 'nais-log-parser', '>= 0.10.0'
25
25
 
26
26
  spec.add_development_dependency "bundler", "~> 1.15"
27
27
  spec.add_development_dependency "rake", "~> 10.0"
@@ -30,6 +30,16 @@ module Fluent::Plugin
30
30
  r['component'] = r.delete('file')
31
31
  r['log'] = r.delete('message')
32
32
  end
33
+ elsif fmt == 'influxdb'
34
+ r = ::Nais::Log::Parser.parse_influxdb(record['log'])
35
+ unless r.nil?
36
+ if r['component'] == 'httpd'
37
+ r['log'] = r.delete('request')
38
+ r['request'] = r.delete('request_id')
39
+ else
40
+ r['log'] = record['log'].sub(/^\S+ /, '')
41
+ end
42
+ end
33
43
  end
34
44
  end
35
45
  if r.nil?
@@ -1,7 +1,7 @@
1
1
  module Fluent
2
2
  module Plugin
3
3
  module Nais
4
- VERSION = "0.6.0"
4
+ VERSION = "0.7.0"
5
5
  end
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fluent-plugin-nais
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.0
4
+ version: 0.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Terje Sannum
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-09-27 00:00:00.000000000 Z
11
+ date: 2017-09-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: fluentd
@@ -28,16 +28,16 @@ dependencies:
28
28
  name: nais-log-parser
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - "~>"
31
+ - - ">="
32
32
  - !ruby/object:Gem::Version
33
- version: '0.9'
33
+ version: 0.10.0
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - "~>"
38
+ - - ">="
39
39
  - !ruby/object:Gem::Version
40
- version: '0.9'
40
+ version: 0.10.0
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: bundler
43
43
  requirement: !ruby/object:Gem::Requirement