fluent-plugin-aws-sqs 1.0.7 → 1.0.8

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
  SHA256:
3
- metadata.gz: 8b990abd70e615e41360393b2046fe07bd5cd7cc731f6ccc47d2b2e57beb11ee
4
- data.tar.gz: ef89442437493a148fb7ecf186776d6e003b87bbd5fd8010b5fd53fdb5215938
3
+ metadata.gz: a8c1deff36f3e9541ecf48e4392fc7b8fe437415352812c3821880a2feaca1f1
4
+ data.tar.gz: 643e7c3ba75ce25bacb798a46d9cc321d51c5ee41241553cc2ce93bf4f5bea3f
5
5
  SHA512:
6
- metadata.gz: c980d96b8570a0451a6d6a70bda842edc5cf4d06b078246181314a176c7886deaadc5450bf09df858bc0045c4f3607b1c5d09f4103c4d1c47fd3271e7dfa7c2f
7
- data.tar.gz: 9b4aa7d5aeef24ee39aa7aab9c6d6a735517968f29efa293b131310f4b3c658d60a0379c9fb0b94524b25f82ebf21899c037e8be15e77c70c64303c6ba4ed84d
6
+ metadata.gz: c2cc8280be51ccd4249220b36d3b341dcf27806e2ab7014544c8e087cd81c060ca31744e319cf8c66549ad92c1116e0b01de0a9eed8d0af0c3b3240e78ab244f
7
+ data.tar.gz: 48181ebda256c55f9b83f3af1ed8d0c7f4650b82aaa89dd95368339f5cbb0323881f8cfc2d9197fac9ba6c30b865312d2233b8338dbe3b621695941a914c4856
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- fluent-plugin-aws-sqs (1.0.5)
4
+ fluent-plugin-aws-sqs (1.0.7)
5
5
  aws-sdk-sqs (>= 1.22.0)
6
6
  fluentd (>= 0.14.0)
7
7
 
@@ -18,6 +18,7 @@ module Fluent::Plugin
18
18
  config_param :visibility_timeout, :integer, default: nil
19
19
  config_param :delete_message, :bool, default: false
20
20
  config_param :stub_responses, :bool, default: false
21
+ config_param :attribute_name_to_extract, :string, default: nil
21
22
 
22
23
  def configure(conf)
23
24
  super
@@ -73,14 +74,19 @@ module Fluent::Plugin
73
74
  end
74
75
 
75
76
  def parse_message(message)
76
- {
77
+ record = {
77
78
  'body' => message.body.to_s,
78
79
  'receipt_handle' => message.receipt_handle.to_s,
79
80
  'message_id' => message.message_id.to_s,
80
81
  'md5_of_body' => message.md5_of_body.to_s,
81
- 'queue_url' => message.queue_url.to_s,
82
- 'sender_id' => message.attributes['SenderId'].to_s
82
+ 'queue_url' => message.queue_url.to_s
83
83
  }
84
+
85
+ if @attribute_name_to_extract.to_s.strip.length > 0
86
+ record[@attribute_name_to_extract] = message.attributes[attribute_name_to_extract].to_s
87
+ end
88
+
89
+ record
84
90
  end
85
91
  end
86
92
  end
@@ -1,3 +1,3 @@
1
1
  module SQS
2
- VERSION = "1.0.7"
2
+ VERSION = "1.0.8"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fluent-plugin-aws-sqs
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.7
4
+ version: 1.0.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Shai Moria
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2019-09-22 00:00:00.000000000 Z
13
+ date: 2019-09-25 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: fluentd