dtomasgu-fluentd 1.14.7.pre.dev → 1.14.8.pre.dev

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
  SHA256:
3
- metadata.gz: bfdbc771913e90e867a59516c9d5df8b2ff1365b7458796e38a894b02a64fa79
4
- data.tar.gz: 65f4736de2323f3015de6d930c0625fe71e41db0e8601d37c5fa9923924e85df
3
+ metadata.gz: 3f1cdd4d415540b1659d527eff72312f3f09afa4531bec64d59319c653e3160b
4
+ data.tar.gz: e1d5556da0395a1e1ed8faf38bb724375714b75dbe6ac3bde471b497f28f9b54
5
5
  SHA512:
6
- metadata.gz: 28fe00aac21ccfede84f57b47203e5568b747fbaa7c76226928c0987471278dfd111ade5f578a61230e0301d9d09731c0bc94803cbfded94a9467ba47fd53a12
7
- data.tar.gz: 5671150c04cb1e4888428cfdbcee2612bebf3c9595dcc7cdb3cc9cb6db5399080347f2c9a8d8bd3dbab5d75ceb3aafec8a2dc8e507b4a7005411bcc8ec69dd6c
6
+ metadata.gz: f200fb63c73de5dfe31b28bbdfc7b233230d222e1f65082d044da6e5db461370aabfc8eedb4ec3ad1cfd56e1bc3b08b23cc3c878b329e7f9cc5fe5ee7bfbe410
7
+ data.tar.gz: 633f3057a68f0065e936d5698fe3f9d0bb29705d41bfbe3f08397ae55a7133f4c74455642f1645b3ee699984714c4a9dae8b2d49aae5ee0d42afba8cd9f2231a
@@ -20,6 +20,8 @@ require 'openssl'
20
20
  require 'fluent/tls'
21
21
  require 'fluent/plugin/output'
22
22
  require 'fluent/plugin_helper/socket'
23
+ require 'json/minify'
24
+
23
25
 
24
26
  # patch Net::HTTP to support extra_chain_cert which was added in Ruby feature #9758.
25
27
  # see: https://github.com/ruby/ruby/commit/31af0dafba6d3769d2a39617c0dddedb97883712
@@ -49,6 +51,8 @@ module Fluent::Plugin
49
51
  config_param :content_type, :string, default: nil
50
52
  desc 'JSON array data format for HTTP request body'
51
53
  config_param :json_array, :bool, default: false
54
+ desc 'Minify exported json data'
55
+ config_param :json_minify, :bool, default: false
52
56
  desc 'Additional headers for HTTP request'
53
57
  config_param :headers, :hash, default: nil
54
58
  desc 'Additional placeholder based headers for HTTP request'
@@ -242,7 +246,7 @@ module Fluent::Plugin
242
246
  set_headers(req, chunk)
243
247
  if @json_minify
244
248
  req.body = JSON.minify(req.body)
245
- req.body = @json_array ? JSON.minify("[#{chunk.read.chop}]") : chunk.read
249
+ req.body = @json_array ? JSON.generate(JSON.minify([#{chunk.read.chop}])) : chunk.read
246
250
  else
247
251
  req.body = @json_array ? "[#{chunk.read.chop}]" : chunk.read
248
252
  end
@@ -16,6 +16,6 @@
16
16
 
17
17
  module Fluent
18
18
 
19
- VERSION = '1.14.7-dev'
19
+ VERSION = '1.14.8-dev'
20
20
 
21
21
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dtomasgu-fluentd
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.14.7.pre.dev
4
+ version: 1.14.8.pre.dev
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sadayuki Furuhashi