fluent-plugin-detect-exceptions 0.0.7 → 0.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 +4 -4
- data/Gemfile.lock +12 -10
- data/fluent-plugin-detect-exceptions.gemspec +1 -1
- data/lib/fluent/plugin/exception_detector.rb +6 -4
- data/test/plugin/test_exception_detector.rb +81 -8
- metadata +3 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 6cbd50429be95c88a0566883dffc3ea4328ab84e
|
|
4
|
+
data.tar.gz: 8ec4336fd0d8afb0b9ffee4b00a30bfe71294cb0
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 92526408d41b2321039acc3b8ae1e15814c52b955e7183392b39ff91141b371ad50d027314183242b456f05fc00dac5a0d9927aaeffb730b4d9e4747e326ce53
|
|
7
|
+
data.tar.gz: 7fc854b59b1b923cf88ef437a3211bdc5a041470517c65618de0c4c1860487d107afa3a970eeb15777f413d2d43880a631a3d835b40096d4fbb29eb12929e9da
|
data/Gemfile.lock
CHANGED
|
@@ -1,19 +1,20 @@
|
|
|
1
1
|
PATH
|
|
2
2
|
remote: .
|
|
3
3
|
specs:
|
|
4
|
-
fluent-plugin-detect-exceptions (0.0.
|
|
4
|
+
fluent-plugin-detect-exceptions (0.0.8)
|
|
5
5
|
fluentd (~> 0.10)
|
|
6
6
|
|
|
7
7
|
GEM
|
|
8
8
|
remote: https://rubygems.org/
|
|
9
9
|
specs:
|
|
10
10
|
ast (2.3.0)
|
|
11
|
-
cool.io (1.5.
|
|
12
|
-
flexmock (2.3.
|
|
13
|
-
fluentd (0.14.
|
|
11
|
+
cool.io (1.5.1)
|
|
12
|
+
flexmock (2.3.6)
|
|
13
|
+
fluentd (0.14.21)
|
|
14
14
|
cool.io (>= 1.4.5, < 2.0.0)
|
|
15
15
|
http_parser.rb (>= 0.5.1, < 0.7.0)
|
|
16
16
|
msgpack (>= 0.7.0, < 2.0.0)
|
|
17
|
+
ruby_dig (~> 0.0.2)
|
|
17
18
|
serverengine (>= 2.0.4, < 3.0.0)
|
|
18
19
|
sigdump (~> 0.2.2)
|
|
19
20
|
strptime (~> 0.1.7)
|
|
@@ -24,7 +25,7 @@ GEM
|
|
|
24
25
|
msgpack (1.1.0)
|
|
25
26
|
parser (2.4.0.0)
|
|
26
27
|
ast (~> 2.2)
|
|
27
|
-
power_assert (1.
|
|
28
|
+
power_assert (1.1.1)
|
|
28
29
|
powerpack (0.1.1)
|
|
29
30
|
rainbow (2.2.2)
|
|
30
31
|
rake
|
|
@@ -35,19 +36,20 @@ GEM
|
|
|
35
36
|
rainbow (>= 1.99.1, < 3.0)
|
|
36
37
|
ruby-progressbar (~> 1.7)
|
|
37
38
|
unicode-display_width (~> 1.0, >= 1.0.1)
|
|
38
|
-
ruby-progressbar (1.
|
|
39
|
+
ruby-progressbar (1.9.0)
|
|
40
|
+
ruby_dig (0.0.2)
|
|
39
41
|
serverengine (2.0.5)
|
|
40
42
|
sigdump (~> 0.2.2)
|
|
41
43
|
sigdump (0.2.4)
|
|
42
44
|
strptime (0.1.9)
|
|
43
|
-
test-unit (3.2.
|
|
45
|
+
test-unit (3.2.6)
|
|
44
46
|
power_assert
|
|
45
47
|
thread_safe (0.3.6)
|
|
46
48
|
tzinfo (1.2.3)
|
|
47
49
|
thread_safe (~> 0.1)
|
|
48
|
-
tzinfo-data (1.2017.
|
|
50
|
+
tzinfo-data (1.2017.3)
|
|
49
51
|
tzinfo (>= 1.0.0)
|
|
50
|
-
unicode-display_width (1.
|
|
52
|
+
unicode-display_width (1.3.0)
|
|
51
53
|
yajl-ruby (1.3.0)
|
|
52
54
|
|
|
53
55
|
PLATFORMS
|
|
@@ -61,4 +63,4 @@ DEPENDENCIES
|
|
|
61
63
|
test-unit (~> 3.0)
|
|
62
64
|
|
|
63
65
|
BUNDLED WITH
|
|
64
|
-
1.15.
|
|
66
|
+
1.15.4
|
|
@@ -11,7 +11,7 @@ eos
|
|
|
11
11
|
gem.homepage = \
|
|
12
12
|
'https://github.com/GoogleCloudPlatform/fluent-plugin-detect-exceptions'
|
|
13
13
|
gem.license = 'Apache-2.0'
|
|
14
|
-
gem.version = '0.0.
|
|
14
|
+
gem.version = '0.0.8'
|
|
15
15
|
gem.authors = ['Thomas Schickinger', 'Igor Peshansky']
|
|
16
16
|
gem.email = ['schickin@google.com', 'igorp@google.com']
|
|
17
17
|
gem.required_ruby_version = Gem::Requirement.new('>= 2.0')
|
|
@@ -75,11 +75,13 @@ module Fluent
|
|
|
75
75
|
].freeze
|
|
76
76
|
|
|
77
77
|
GO_RULES = [
|
|
78
|
-
rule(:start_state,
|
|
79
|
-
rule(:
|
|
78
|
+
rule(:start_state, /\bpanic: /, :go_after_panic),
|
|
79
|
+
rule(:go_after_panic, /^$/, :go_goroutine),
|
|
80
|
+
rule(:go_after_panic, /^\[signal /, :go_after_signal),
|
|
81
|
+
rule(:go_after_signal, /^$/, :go_goroutine),
|
|
80
82
|
rule(:go_goroutine, /^goroutine \d+ \[[^\]]+\]:$/, :go_frame_1),
|
|
81
|
-
rule(:go_frame_1,
|
|
82
|
-
rule(:go_frame_1, /^$/, :
|
|
83
|
+
rule(:go_frame_1, /^(?:[^\s.:]+\.)*[^\s.():]+\(|^created by /, :go_frame_2),
|
|
84
|
+
rule(:go_frame_1, /^$/, :go_goroutine),
|
|
83
85
|
rule(:go_frame_2, /^\s/, :go_frame_1)
|
|
84
86
|
].freeze
|
|
85
87
|
|
|
@@ -126,25 +126,92 @@ Stack trace:
|
|
|
126
126
|
END
|
|
127
127
|
|
|
128
128
|
GO_EXC = <<END.freeze
|
|
129
|
+
panic: my panic
|
|
130
|
+
|
|
131
|
+
goroutine 4 [running]:
|
|
132
|
+
panic(0x45cb40, 0x47ad70)
|
|
133
|
+
/usr/local/go/src/runtime/panic.go:542 +0x46c fp=0xc42003f7b8 sp=0xc42003f710 pc=0x422f7c
|
|
134
|
+
main.main.func1(0xc420024120)
|
|
135
|
+
foo.go:6 +0x39 fp=0xc42003f7d8 sp=0xc42003f7b8 pc=0x451339
|
|
136
|
+
runtime.goexit()
|
|
137
|
+
/usr/local/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42003f7e0 sp=0xc42003f7d8 pc=0x44b4d1
|
|
138
|
+
created by main.main
|
|
139
|
+
foo.go:5 +0x58
|
|
140
|
+
|
|
141
|
+
goroutine 1 [chan receive]:
|
|
142
|
+
runtime.gopark(0x4739b8, 0xc420024178, 0x46fcd7, 0xc, 0xc420028e17, 0x3)
|
|
143
|
+
/usr/local/go/src/runtime/proc.go:280 +0x12c fp=0xc420053e30 sp=0xc420053e00 pc=0x42503c
|
|
144
|
+
runtime.goparkunlock(0xc420024178, 0x46fcd7, 0xc, 0x1000f010040c217, 0x3)
|
|
145
|
+
/usr/local/go/src/runtime/proc.go:286 +0x5e fp=0xc420053e70 sp=0xc420053e30 pc=0x42512e
|
|
146
|
+
runtime.chanrecv(0xc420024120, 0x0, 0xc420053f01, 0x4512d8)
|
|
147
|
+
/usr/local/go/src/runtime/chan.go:506 +0x304 fp=0xc420053f20 sp=0xc420053e70 pc=0x4046b4
|
|
148
|
+
runtime.chanrecv1(0xc420024120, 0x0)
|
|
149
|
+
/usr/local/go/src/runtime/chan.go:388 +0x2b fp=0xc420053f50 sp=0xc420053f20 pc=0x40439b
|
|
150
|
+
main.main()
|
|
151
|
+
foo.go:9 +0x6f fp=0xc420053f80 sp=0xc420053f50 pc=0x4512ef
|
|
152
|
+
runtime.main()
|
|
153
|
+
/usr/local/go/src/runtime/proc.go:185 +0x20d fp=0xc420053fe0 sp=0xc420053f80 pc=0x424bad
|
|
154
|
+
runtime.goexit()
|
|
155
|
+
/usr/local/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc420053fe8 sp=0xc420053fe0 pc=0x44b4d1
|
|
156
|
+
|
|
157
|
+
goroutine 2 [force gc (idle)]:
|
|
158
|
+
runtime.gopark(0x4739b8, 0x4ad720, 0x47001e, 0xf, 0x14, 0x1)
|
|
159
|
+
/usr/local/go/src/runtime/proc.go:280 +0x12c fp=0xc42003e768 sp=0xc42003e738 pc=0x42503c
|
|
160
|
+
runtime.goparkunlock(0x4ad720, 0x47001e, 0xf, 0xc420000114, 0x1)
|
|
161
|
+
/usr/local/go/src/runtime/proc.go:286 +0x5e fp=0xc42003e7a8 sp=0xc42003e768 pc=0x42512e
|
|
162
|
+
runtime.forcegchelper()
|
|
163
|
+
/usr/local/go/src/runtime/proc.go:238 +0xcc fp=0xc42003e7e0 sp=0xc42003e7a8 pc=0x424e5c
|
|
164
|
+
runtime.goexit()
|
|
165
|
+
/usr/local/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42003e7e8 sp=0xc42003e7e0 pc=0x44b4d1
|
|
166
|
+
created by runtime.init.4
|
|
167
|
+
/usr/local/go/src/runtime/proc.go:227 +0x35
|
|
168
|
+
|
|
169
|
+
goroutine 3 [GC sweep wait]:
|
|
170
|
+
runtime.gopark(0x4739b8, 0x4ad7e0, 0x46fdd2, 0xd, 0x419914, 0x1)
|
|
171
|
+
/usr/local/go/src/runtime/proc.go:280 +0x12c fp=0xc42003ef60 sp=0xc42003ef30 pc=0x42503c
|
|
172
|
+
runtime.goparkunlock(0x4ad7e0, 0x46fdd2, 0xd, 0x14, 0x1)
|
|
173
|
+
/usr/local/go/src/runtime/proc.go:286 +0x5e fp=0xc42003efa0 sp=0xc42003ef60 pc=0x42512e
|
|
174
|
+
runtime.bgsweep(0xc42001e150)
|
|
175
|
+
/usr/local/go/src/runtime/mgcsweep.go:52 +0xa3 fp=0xc42003efd8 sp=0xc42003efa0 pc=0x419973
|
|
176
|
+
runtime.goexit()
|
|
177
|
+
/usr/local/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42003efe0 sp=0xc42003efd8 pc=0x44b4d1
|
|
178
|
+
created by runtime.gcenable
|
|
179
|
+
/usr/local/go/src/runtime/mgc.go:216 +0x58
|
|
180
|
+
END
|
|
181
|
+
|
|
182
|
+
GO_ON_GAE_EXC = <<END.freeze
|
|
129
183
|
panic: runtime error: index out of range
|
|
130
184
|
|
|
131
185
|
goroutine 12 [running]:
|
|
132
186
|
main88989.memoryAccessException()
|
|
133
|
-
|
|
187
|
+
crash_example_go.go:58 +0x12a
|
|
134
188
|
main88989.handler(0x2afb7042a408, 0xc01042f880, 0xc0104d3450)
|
|
135
|
-
|
|
189
|
+
crash_example_go.go:36 +0x7ec
|
|
136
190
|
net/http.HandlerFunc.ServeHTTP(0x13e5128, 0x2afb7042a408, 0xc01042f880, 0xc0104d3450)
|
|
137
|
-
|
|
191
|
+
go/src/net/http/server.go:1265 +0x56
|
|
138
192
|
net/http.(*ServeMux).ServeHTTP(0xc01045cab0, 0x2afb7042a408, 0xc01042f880, 0xc0104d3450)
|
|
139
|
-
|
|
193
|
+
go/src/net/http/server.go:1541 +0x1b4
|
|
140
194
|
appengine_internal.executeRequestSafely(0xc01042f880, 0xc0104d3450)
|
|
141
|
-
|
|
195
|
+
go/src/appengine_internal/api_prod.go:288 +0xb7
|
|
142
196
|
appengine_internal.(*server).HandleRequest(0x15819b0, 0xc010401560, 0xc0104c8180, 0xc010431380, 0x0, 0x0)
|
|
143
|
-
|
|
197
|
+
go/src/appengine_internal/api_prod.go:222 +0x102b
|
|
144
198
|
reflect.Value.call(0x1243fe0, 0x15819b0, 0x113, 0x12c8a20, 0x4, 0xc010485f78, 0x3, 0x3, 0x0, 0x0, ...)
|
|
145
|
-
|
|
199
|
+
/tmp/appengine/go/src/reflect/value.go:419 +0x10fd
|
|
146
200
|
reflect.Value.Call(0x1243fe0, 0x15819b0, 0x113, 0xc010485f78, 0x3, 0x3, 0x0, 0x0, 0x0)
|
|
147
|
-
|
|
201
|
+
/tmp/ap
|
|
202
|
+
END
|
|
203
|
+
|
|
204
|
+
GO_SIGNAL_EXC = <<END.freeze
|
|
205
|
+
panic: runtime error: invalid memory address or nil pointer dereference
|
|
206
|
+
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x7fd34f]
|
|
207
|
+
|
|
208
|
+
goroutine 5 [running]:
|
|
209
|
+
panics.nilPtrDereference()
|
|
210
|
+
panics/panics.go:33 +0x1f
|
|
211
|
+
panics.Wait()
|
|
212
|
+
panics/panics.go:16 +0x3b
|
|
213
|
+
created by main.main
|
|
214
|
+
server.go:20 +0x91
|
|
148
215
|
END
|
|
149
216
|
|
|
150
217
|
CSHARP_EXC = <<END.freeze
|
|
@@ -205,6 +272,8 @@ END
|
|
|
205
272
|
|
|
206
273
|
ARBITRARY_TEXT = <<END.freeze
|
|
207
274
|
This arbitrary text.
|
|
275
|
+
It sounds tympanic: a word which means like a drum.
|
|
276
|
+
|
|
208
277
|
I am glad it contains no exception.
|
|
209
278
|
END
|
|
210
279
|
|
|
@@ -269,6 +338,8 @@ END
|
|
|
269
338
|
|
|
270
339
|
def test_go
|
|
271
340
|
check_exception(GO_EXC, false)
|
|
341
|
+
check_exception(GO_ON_GAE_EXC, false)
|
|
342
|
+
check_exception(GO_SIGNAL_EXC, false)
|
|
272
343
|
end
|
|
273
344
|
|
|
274
345
|
def test_ruby
|
|
@@ -285,6 +356,8 @@ END
|
|
|
285
356
|
check_exception(PHP_ON_GAE_EXC, true)
|
|
286
357
|
check_exception(CLIENT_JS_EXC, false)
|
|
287
358
|
check_exception(GO_EXC, false)
|
|
359
|
+
check_exception(GO_ON_GAE_EXC, false)
|
|
360
|
+
check_exception(GO_SIGNAL_EXC, false)
|
|
288
361
|
check_exception(CSHARP_EXC, false)
|
|
289
362
|
check_exception(V8_JS_EXC, false)
|
|
290
363
|
check_exception(RUBY_EXC, false)
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: fluent-plugin-detect-exceptions
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0.
|
|
4
|
+
version: 0.0.8
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Thomas Schickinger
|
|
@@ -9,7 +9,7 @@ authors:
|
|
|
9
9
|
autorequire:
|
|
10
10
|
bindir: bin
|
|
11
11
|
cert_chain: []
|
|
12
|
-
date: 2017-10-
|
|
12
|
+
date: 2017-10-25 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
14
|
- !ruby/object:Gem::Dependency
|
|
15
15
|
name: fluentd
|
|
@@ -126,7 +126,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
126
126
|
version: '0'
|
|
127
127
|
requirements: []
|
|
128
128
|
rubyforge_project:
|
|
129
|
-
rubygems_version: 2.
|
|
129
|
+
rubygems_version: 2.4.8
|
|
130
130
|
signing_key:
|
|
131
131
|
specification_version: 4
|
|
132
132
|
summary: fluentd output plugin for combining stack traces as multi-line JSON logs
|