fluent-plugin-sqs 1.3.2 → 1.4.4
Sign up to get free protection for your applications and to get access to all the features.
- data/Rakefile +1 -21
- data/VERSION +1 -1
- data/lib/fluent/plugin/in_sqs.rb +6 -6
- data/spec/lib/fluent/plugin/in_sqs_spec.rb +14 -14
- metadata +41 -23
- checksums.yaml +0 -7
data/Rakefile
CHANGED
@@ -1,27 +1,7 @@
|
|
1
1
|
require 'rake'
|
2
2
|
require 'rake/testtask'
|
3
3
|
require 'rake/clean'
|
4
|
-
|
5
|
-
begin
|
6
|
-
require 'jeweler'
|
7
|
-
Jeweler::Tasks.new do |gemspec|
|
8
|
-
gemspec.name = "fluent-plugin-sqs"
|
9
|
-
gemspec.summary = "Amazon SQS input/output plugin for Fluent event collector"
|
10
|
-
gemspec.author = "Yuri Odagiri"
|
11
|
-
gemspec.email = "ixixizko@gmail.com"
|
12
|
-
gemspec.homepage = "https://github.com/ixixi/fluent-plugin-sqs"
|
13
|
-
gemspec.has_rdoc = false
|
14
|
-
gemspec.require_paths = ["lib"]
|
15
|
-
gemspec.add_dependency "fluentd", "~> 0.10.0"
|
16
|
-
gemspec.add_dependency "aws-sdk", "~> 1.3.2"
|
17
|
-
gemspec.test_files = Dir["test/**/*.rb", "spec/**/*.rb"]
|
18
|
-
gemspec.files = Dir["lib/**/*", "test/**/*.rb", "spec/**/*.rb"] + %w[VERSION AUTHORS Rakefile]
|
19
|
-
gemspec.executables = []
|
20
|
-
end
|
21
|
-
Jeweler::GemcutterTasks.new
|
22
|
-
rescue LoadError
|
23
|
-
puts "Jeweler not available. Install it with: gem install jeweler"
|
24
|
-
end
|
4
|
+
require "bundler/gem_tasks"
|
25
5
|
|
26
6
|
Rake::TestTask.new(:test) do |t|
|
27
7
|
t.test_files = Dir['test/*_test.rb']
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.
|
1
|
+
1.4.4
|
data/lib/fluent/plugin/in_sqs.rb
CHANGED
@@ -48,12 +48,12 @@ module Fluent
|
|
48
48
|
sleep @receive_interval
|
49
49
|
@queue.receive_message do |message|
|
50
50
|
record = {}
|
51
|
-
record[
|
52
|
-
record[
|
53
|
-
record[
|
54
|
-
record[
|
55
|
-
record[
|
56
|
-
record[
|
51
|
+
record['body'] = message.body.to_s
|
52
|
+
record['handle'] = message.handle.to_s
|
53
|
+
record['id'] = message.id.to_s
|
54
|
+
record['md5'] = message.md5.to_s
|
55
|
+
record['url'] = message.queue.url.to_s
|
56
|
+
record['sender_id'] = message.sender_id.to_s
|
57
57
|
|
58
58
|
Engine.emit(@tag, Time.now.to_i, record)
|
59
59
|
end
|
@@ -45,27 +45,27 @@ describe do
|
|
45
45
|
|
46
46
|
describe 'emit' do
|
47
47
|
let(:message) do
|
48
|
-
{
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
48
|
+
{ 'body' => 'body',
|
49
|
+
'handle' => 'handle',
|
50
|
+
'id' => 'id',
|
51
|
+
'md5' => 'md5',
|
52
|
+
'url' => 'url',
|
53
|
+
'sender_id' => 'sender_id'
|
54
54
|
}
|
55
55
|
end
|
56
56
|
let(:emmits) {
|
57
|
-
|
57
|
+
allow(Time).to receive(:now).and_return(0)
|
58
58
|
|
59
59
|
class AWS::SQS::Queue
|
60
60
|
def receive_message
|
61
61
|
yield OpenStruct.new(
|
62
|
-
{
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
62
|
+
{ 'body' => 'body',
|
63
|
+
'handle' => 'handle',
|
64
|
+
'id' => 'id',
|
65
|
+
'md5' => 'md5',
|
66
|
+
'queue' => OpenStruct.new(:url => 'url'),
|
67
|
+
'sender_id' => 'sender_id',
|
68
|
+
'sent_at' => 0
|
69
69
|
})
|
70
70
|
end
|
71
71
|
end
|
metadata
CHANGED
@@ -1,125 +1,142 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fluent-plugin-sqs
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.4.4
|
5
|
+
prerelease:
|
5
6
|
platform: ruby
|
6
7
|
authors:
|
7
8
|
- Yuri Odagiri
|
8
9
|
autorequire:
|
9
10
|
bindir: bin
|
10
11
|
cert_chain: []
|
11
|
-
date: 2014-
|
12
|
+
date: 2014-11-07 00:00:00.000000000 Z
|
12
13
|
dependencies:
|
13
14
|
- !ruby/object:Gem::Dependency
|
14
15
|
name: fluentd
|
15
16
|
requirement: !ruby/object:Gem::Requirement
|
17
|
+
none: false
|
16
18
|
requirements:
|
17
|
-
- -
|
19
|
+
- - ~>
|
18
20
|
- !ruby/object:Gem::Version
|
19
21
|
version: 0.10.0
|
20
22
|
type: :runtime
|
21
23
|
prerelease: false
|
22
24
|
version_requirements: !ruby/object:Gem::Requirement
|
25
|
+
none: false
|
23
26
|
requirements:
|
24
|
-
- -
|
27
|
+
- - ~>
|
25
28
|
- !ruby/object:Gem::Version
|
26
29
|
version: 0.10.0
|
27
30
|
- !ruby/object:Gem::Dependency
|
28
31
|
name: aws-sdk
|
29
32
|
requirement: !ruby/object:Gem::Requirement
|
33
|
+
none: false
|
30
34
|
requirements:
|
31
|
-
- -
|
35
|
+
- - ~>
|
32
36
|
- !ruby/object:Gem::Version
|
33
37
|
version: 1.9.5
|
34
38
|
type: :runtime
|
35
39
|
prerelease: false
|
36
40
|
version_requirements: !ruby/object:Gem::Requirement
|
41
|
+
none: false
|
37
42
|
requirements:
|
38
|
-
- -
|
43
|
+
- - ~>
|
39
44
|
- !ruby/object:Gem::Version
|
40
45
|
version: 1.9.5
|
41
46
|
- !ruby/object:Gem::Dependency
|
42
47
|
name: bundler
|
43
48
|
requirement: !ruby/object:Gem::Requirement
|
49
|
+
none: false
|
44
50
|
requirements:
|
45
|
-
- -
|
51
|
+
- - ! '>='
|
46
52
|
- !ruby/object:Gem::Version
|
47
53
|
version: '0'
|
48
54
|
type: :development
|
49
55
|
prerelease: false
|
50
56
|
version_requirements: !ruby/object:Gem::Requirement
|
57
|
+
none: false
|
51
58
|
requirements:
|
52
|
-
- -
|
59
|
+
- - ! '>='
|
53
60
|
- !ruby/object:Gem::Version
|
54
61
|
version: '0'
|
55
62
|
- !ruby/object:Gem::Dependency
|
56
63
|
name: rake
|
57
64
|
requirement: !ruby/object:Gem::Requirement
|
65
|
+
none: false
|
58
66
|
requirements:
|
59
|
-
- -
|
67
|
+
- - ! '>='
|
60
68
|
- !ruby/object:Gem::Version
|
61
69
|
version: '0'
|
62
70
|
type: :development
|
63
71
|
prerelease: false
|
64
72
|
version_requirements: !ruby/object:Gem::Requirement
|
73
|
+
none: false
|
65
74
|
requirements:
|
66
|
-
- -
|
75
|
+
- - ! '>='
|
67
76
|
- !ruby/object:Gem::Version
|
68
77
|
version: '0'
|
69
78
|
- !ruby/object:Gem::Dependency
|
70
79
|
name: rspec
|
71
80
|
requirement: !ruby/object:Gem::Requirement
|
81
|
+
none: false
|
72
82
|
requirements:
|
73
|
-
- -
|
83
|
+
- - ! '>='
|
74
84
|
- !ruby/object:Gem::Version
|
75
85
|
version: '0'
|
76
86
|
type: :development
|
77
87
|
prerelease: false
|
78
88
|
version_requirements: !ruby/object:Gem::Requirement
|
89
|
+
none: false
|
79
90
|
requirements:
|
80
|
-
- -
|
91
|
+
- - ! '>='
|
81
92
|
- !ruby/object:Gem::Version
|
82
93
|
version: '0'
|
83
94
|
- !ruby/object:Gem::Dependency
|
84
95
|
name: rr
|
85
96
|
requirement: !ruby/object:Gem::Requirement
|
97
|
+
none: false
|
86
98
|
requirements:
|
87
|
-
- -
|
99
|
+
- - ! '>='
|
88
100
|
- !ruby/object:Gem::Version
|
89
101
|
version: '0'
|
90
102
|
type: :development
|
91
103
|
prerelease: false
|
92
104
|
version_requirements: !ruby/object:Gem::Requirement
|
105
|
+
none: false
|
93
106
|
requirements:
|
94
|
-
- -
|
107
|
+
- - ! '>='
|
95
108
|
- !ruby/object:Gem::Version
|
96
109
|
version: '0'
|
97
110
|
- !ruby/object:Gem::Dependency
|
98
111
|
name: pry
|
99
112
|
requirement: !ruby/object:Gem::Requirement
|
113
|
+
none: false
|
100
114
|
requirements:
|
101
|
-
- -
|
115
|
+
- - ! '>='
|
102
116
|
- !ruby/object:Gem::Version
|
103
117
|
version: '0'
|
104
118
|
type: :development
|
105
119
|
prerelease: false
|
106
120
|
version_requirements: !ruby/object:Gem::Requirement
|
121
|
+
none: false
|
107
122
|
requirements:
|
108
|
-
- -
|
123
|
+
- - ! '>='
|
109
124
|
- !ruby/object:Gem::Version
|
110
125
|
version: '0'
|
111
126
|
- !ruby/object:Gem::Dependency
|
112
127
|
name: jeweler
|
113
128
|
requirement: !ruby/object:Gem::Requirement
|
129
|
+
none: false
|
114
130
|
requirements:
|
115
|
-
- -
|
131
|
+
- - ! '>='
|
116
132
|
- !ruby/object:Gem::Version
|
117
133
|
version: '0'
|
118
134
|
type: :development
|
119
135
|
prerelease: false
|
120
136
|
version_requirements: !ruby/object:Gem::Requirement
|
137
|
+
none: false
|
121
138
|
requirements:
|
122
|
-
- -
|
139
|
+
- - ! '>='
|
123
140
|
- !ruby/object:Gem::Version
|
124
141
|
version: '0'
|
125
142
|
description:
|
@@ -130,33 +147,34 @@ extra_rdoc_files:
|
|
130
147
|
- README.rdoc
|
131
148
|
files:
|
132
149
|
- AUTHORS
|
133
|
-
- README.rdoc
|
134
150
|
- Rakefile
|
135
151
|
- VERSION
|
136
152
|
- lib/fluent/plugin/in_sqs.rb
|
137
153
|
- lib/fluent/plugin/out_sqs.rb
|
138
154
|
- spec/lib/fluent/plugin/in_sqs_spec.rb
|
139
155
|
- spec/spec_helper.rb
|
156
|
+
- README.rdoc
|
140
157
|
homepage: https://github.com/ixixi/fluent-plugin-sqs
|
141
158
|
licenses: []
|
142
|
-
metadata: {}
|
143
159
|
post_install_message:
|
144
160
|
rdoc_options: []
|
145
161
|
require_paths:
|
146
162
|
- lib
|
147
163
|
required_ruby_version: !ruby/object:Gem::Requirement
|
164
|
+
none: false
|
148
165
|
requirements:
|
149
|
-
- -
|
166
|
+
- - ! '>='
|
150
167
|
- !ruby/object:Gem::Version
|
151
168
|
version: '0'
|
152
169
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
170
|
+
none: false
|
153
171
|
requirements:
|
154
|
-
- -
|
172
|
+
- - ! '>='
|
155
173
|
- !ruby/object:Gem::Version
|
156
174
|
version: '0'
|
157
175
|
requirements: []
|
158
176
|
rubyforge_project:
|
159
|
-
rubygems_version:
|
177
|
+
rubygems_version: 1.8.23.2
|
160
178
|
signing_key:
|
161
179
|
specification_version: 3
|
162
180
|
summary: Amazon SQS input/output plugin for Fluent event collector
|
checksums.yaml
DELETED
@@ -1,7 +0,0 @@
|
|
1
|
-
---
|
2
|
-
SHA1:
|
3
|
-
metadata.gz: 5f161e594dede0f0faa3968a5ccd1d0bdbdab953
|
4
|
-
data.tar.gz: 7683c7284219c1d6c0bfb67610bcf2b3232a981e
|
5
|
-
SHA512:
|
6
|
-
metadata.gz: d01cbf2271a256c8b30b8417a2c772c4947231ef05106adf092b5bb656679b5cc20674a1784c20e1efd0c8cbf241a66234257d6ef1e2ba162ac27cc15f93cee3
|
7
|
-
data.tar.gz: eae155c6624f3f5916c556ea63ea76ce8155c018c283785536e4e6a750fb1c210c173716ba5aaff00dcb3747871d04fb6ab7a99d2b545b1169780ae7028da5a7
|