fluentd 0.10.18 → 0.10.19
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of fluentd might be problematic. Click here for more details.
- data/ChangeLog +7 -0
- data/VERSION +1 -1
- data/lib/fluent/plugin/in_stream.rb +1 -2
- data/lib/fluent/plugin/in_syslog.rb +38 -8
- data/lib/fluent/plugin/in_tail.rb +2 -2
- data/lib/fluent/version.rb +1 -1
- metadata +20 -20
data/ChangeLog
CHANGED
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.10.
|
1
|
+
0.10.19
|
@@ -175,7 +175,6 @@ class TcpInput < ForwardInput
|
|
175
175
|
end
|
176
176
|
|
177
177
|
|
178
|
-
# obsolete
|
179
178
|
class UnixInput < StreamInput
|
180
179
|
Plugin.register_input('unix', self)
|
181
180
|
|
@@ -183,7 +182,7 @@ class UnixInput < StreamInput
|
|
183
182
|
|
184
183
|
def configure(conf)
|
185
184
|
super
|
186
|
-
|
185
|
+
#$log.warn "'unix' input is obsoleted and will be removed. Use 'forward' instead."
|
187
186
|
end
|
188
187
|
|
189
188
|
def listen
|
@@ -89,9 +89,34 @@ class SyslogInput < Input
|
|
89
89
|
else
|
90
90
|
callback = method(:receive_data)
|
91
91
|
end
|
92
|
-
|
92
|
+
|
93
|
+
@loop = Coolio::Loop.new
|
94
|
+
|
95
|
+
$log.debug "listening syslog socket on #{@bind}:#{@port}"
|
96
|
+
@usock = UDPSocket.new
|
97
|
+
@usock.bind(@bind, @port)
|
98
|
+
|
99
|
+
@handler = UdpHandler.new(@usock, callback)
|
100
|
+
@loop.attach(@handler)
|
101
|
+
|
102
|
+
@thread = Thread.new(&method(:run))
|
103
|
+
end
|
104
|
+
|
105
|
+
def shutdown
|
106
|
+
@loop.watchers.each {|w| w.detach }
|
107
|
+
@loop.stop
|
108
|
+
@handler.close
|
109
|
+
@thread.join
|
110
|
+
end
|
111
|
+
|
112
|
+
def run
|
113
|
+
@loop.run
|
114
|
+
rescue
|
115
|
+
$log.error "unexpected error", :error=>$!.to_s
|
116
|
+
$log.error_backtrace
|
93
117
|
end
|
94
118
|
|
119
|
+
protected
|
95
120
|
def receive_data_parser(data)
|
96
121
|
m = SYSLOG_REGEXP.match(data)
|
97
122
|
unless m
|
@@ -156,16 +181,21 @@ class SyslogInput < Input
|
|
156
181
|
Engine.emit(tag, time, record)
|
157
182
|
end
|
158
183
|
|
159
|
-
class UdpHandler <
|
160
|
-
def initialize(callback)
|
161
|
-
super()
|
184
|
+
class UdpHandler < Coolio::IO
|
185
|
+
def initialize(io, callback)
|
186
|
+
super(io)
|
187
|
+
@io = io
|
162
188
|
@callback = callback
|
163
189
|
end
|
164
190
|
|
165
|
-
def
|
166
|
-
|
167
|
-
|
168
|
-
|
191
|
+
def on_readable
|
192
|
+
msg, addr = @io.recvfrom_nonblock(1024)
|
193
|
+
#host = addr[3]
|
194
|
+
#port = addr[1]
|
195
|
+
#@callback.call(host, port, msg)
|
196
|
+
@callback.call(msg)
|
197
|
+
rescue
|
198
|
+
# TODO log?
|
169
199
|
end
|
170
200
|
end
|
171
201
|
end
|
data/lib/fluent/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fluentd
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.10.
|
4
|
+
version: 0.10.19
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,11 +9,11 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2012-04-
|
12
|
+
date: 2012-04-17 00:00:00.000000000Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: msgpack
|
16
|
-
requirement: &
|
16
|
+
requirement: &70342941850580 !ruby/object:Gem::Requirement
|
17
17
|
none: false
|
18
18
|
requirements:
|
19
19
|
- - ~>
|
@@ -21,10 +21,10 @@ dependencies:
|
|
21
21
|
version: 0.4.4
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
|
-
version_requirements: *
|
24
|
+
version_requirements: *70342941850580
|
25
25
|
- !ruby/object:Gem::Dependency
|
26
26
|
name: json
|
27
|
-
requirement: &
|
27
|
+
requirement: &70342941849920 !ruby/object:Gem::Requirement
|
28
28
|
none: false
|
29
29
|
requirements:
|
30
30
|
- - ! '>='
|
@@ -32,10 +32,10 @@ dependencies:
|
|
32
32
|
version: 1.4.3
|
33
33
|
type: :runtime
|
34
34
|
prerelease: false
|
35
|
-
version_requirements: *
|
35
|
+
version_requirements: *70342941849920
|
36
36
|
- !ruby/object:Gem::Dependency
|
37
37
|
name: yajl-ruby
|
38
|
-
requirement: &
|
38
|
+
requirement: &70342941849140 !ruby/object:Gem::Requirement
|
39
39
|
none: false
|
40
40
|
requirements:
|
41
41
|
- - ~>
|
@@ -43,10 +43,10 @@ dependencies:
|
|
43
43
|
version: '1.0'
|
44
44
|
type: :runtime
|
45
45
|
prerelease: false
|
46
|
-
version_requirements: *
|
46
|
+
version_requirements: *70342941849140
|
47
47
|
- !ruby/object:Gem::Dependency
|
48
48
|
name: cool.io
|
49
|
-
requirement: &
|
49
|
+
requirement: &70342941848200 !ruby/object:Gem::Requirement
|
50
50
|
none: false
|
51
51
|
requirements:
|
52
52
|
- - ~>
|
@@ -54,10 +54,10 @@ dependencies:
|
|
54
54
|
version: 1.1.0
|
55
55
|
type: :runtime
|
56
56
|
prerelease: false
|
57
|
-
version_requirements: *
|
57
|
+
version_requirements: *70342941848200
|
58
58
|
- !ruby/object:Gem::Dependency
|
59
59
|
name: http_parser.rb
|
60
|
-
requirement: &
|
60
|
+
requirement: &70342941847500 !ruby/object:Gem::Requirement
|
61
61
|
none: false
|
62
62
|
requirements:
|
63
63
|
- - ~>
|
@@ -65,10 +65,10 @@ dependencies:
|
|
65
65
|
version: 0.5.1
|
66
66
|
type: :runtime
|
67
67
|
prerelease: false
|
68
|
-
version_requirements: *
|
68
|
+
version_requirements: *70342941847500
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: rake
|
71
|
-
requirement: &
|
71
|
+
requirement: &70342941846860 !ruby/object:Gem::Requirement
|
72
72
|
none: false
|
73
73
|
requirements:
|
74
74
|
- - ! '>='
|
@@ -76,10 +76,10 @@ dependencies:
|
|
76
76
|
version: 0.9.2
|
77
77
|
type: :development
|
78
78
|
prerelease: false
|
79
|
-
version_requirements: *
|
79
|
+
version_requirements: *70342941846860
|
80
80
|
- !ruby/object:Gem::Dependency
|
81
81
|
name: rr
|
82
|
-
requirement: &
|
82
|
+
requirement: &70342941846100 !ruby/object:Gem::Requirement
|
83
83
|
none: false
|
84
84
|
requirements:
|
85
85
|
- - ! '>='
|
@@ -87,10 +87,10 @@ dependencies:
|
|
87
87
|
version: 1.0.0
|
88
88
|
type: :development
|
89
89
|
prerelease: false
|
90
|
-
version_requirements: *
|
90
|
+
version_requirements: *70342941846100
|
91
91
|
- !ruby/object:Gem::Dependency
|
92
92
|
name: timecop
|
93
|
-
requirement: &
|
93
|
+
requirement: &70342941845440 !ruby/object:Gem::Requirement
|
94
94
|
none: false
|
95
95
|
requirements:
|
96
96
|
- - ! '>='
|
@@ -98,10 +98,10 @@ dependencies:
|
|
98
98
|
version: 0.3.0
|
99
99
|
type: :development
|
100
100
|
prerelease: false
|
101
|
-
version_requirements: *
|
101
|
+
version_requirements: *70342941845440
|
102
102
|
- !ruby/object:Gem::Dependency
|
103
103
|
name: jeweler
|
104
|
-
requirement: &
|
104
|
+
requirement: &70342941844840 !ruby/object:Gem::Requirement
|
105
105
|
none: false
|
106
106
|
requirements:
|
107
107
|
- - ! '>='
|
@@ -109,7 +109,7 @@ dependencies:
|
|
109
109
|
version: 1.0.0
|
110
110
|
type: :development
|
111
111
|
prerelease: false
|
112
|
-
version_requirements: *
|
112
|
+
version_requirements: *70342941844840
|
113
113
|
description:
|
114
114
|
email: frsyuki@gmail.com
|
115
115
|
executables:
|