logstash-output-logservice 0.1.0 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/logstash/outputs/logservice.rb +6 -6
- data/logstash-output-logservice.gemspec +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5ceec20c00719163e5c5973e3ec5adb32f656ac5
|
4
|
+
data.tar.gz: ca1fe9f695e8fb80f4ec5919ea0c4d4294b4f55a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6dee2854d218ab0cd9b53477c967a40096488500862292c31ee41a22ad181678769b5656a71324c46908d9a52e96c37ba8db287b1c6c6d22a2d2a4c01c8ec738
|
7
|
+
data.tar.gz: 3f0caa777fcec257ee21d0f8b8100617678f2c7027a241ae95c9ceb253f8d99b217d8d0b0032c1abad6bc6e93af32d20403ef8c05ce95c8b8821897477555a35
|
@@ -36,10 +36,10 @@ class LogStash::Outputs::LogService < LogStash::Outputs::Base
|
|
36
36
|
# for batch send, logGroup will emit in default 3 seconds
|
37
37
|
config :max_buffer_seconds, :validate=> :number, :required=> false, :default=> 3
|
38
38
|
|
39
|
-
# logGroup will retry send to log service when error happened, and will be discard when retry times exceed limit
|
40
|
-
config :max_send_retry, :validate=> :number, :required=> true, :default=>
|
39
|
+
# logGroup will retry send to log service when error happened, and will be discard when retry times exceed limit
|
40
|
+
config :max_send_retry, :validate=> :number, :required=> true, :default=> 10
|
41
41
|
# sleep default 100 milliseconds before retry next send
|
42
|
-
config :send_retry_interval, :validate=> :number, :required=> false, :default=>
|
42
|
+
config :send_retry_interval, :validate=> :number, :required=> false, :default=> 200
|
43
43
|
|
44
44
|
Log = com.aliyun.openservices.log
|
45
45
|
LogException = com.aliyun.openservices.log.exception.LogException
|
@@ -80,7 +80,7 @@ class LogStash::Outputs::LogService < LogStash::Outputs::Base
|
|
80
80
|
@error_code = e.GetErrorCode()
|
81
81
|
@error_message = e.GetErrorMessage()
|
82
82
|
if @retry < @max_send_retry
|
83
|
-
@logger.
|
83
|
+
@logger.warn("send logs to logservice fail, will retry soon", :exception => e, :error_code => @error_code, :error_message => @error_message, :retry => @retry)
|
84
84
|
sleep(@send_retry_interval_seconds)
|
85
85
|
retry
|
86
86
|
else
|
@@ -88,7 +88,7 @@ class LogStash::Outputs::LogService < LogStash::Outputs::Base
|
|
88
88
|
end
|
89
89
|
rescue => e
|
90
90
|
if @retry < @max_send_retry
|
91
|
-
@logger.
|
91
|
+
@logger.warn("send logs to logservice fail, will retry soon", :exception => e, :retry => @retry)
|
92
92
|
sleep(@send_retry_interval_seconds)
|
93
93
|
retry
|
94
94
|
else
|
@@ -140,4 +140,4 @@ class LogStash::Outputs::LogService < LogStash::Outputs::Base
|
|
140
140
|
buffer_flush(:final => true)
|
141
141
|
end # def close
|
142
142
|
|
143
|
-
end # class LogStash::Outputs::LogService
|
143
|
+
end # class LogStash::Outputs::LogService
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Gem::Specification.new do |s|
|
2
2
|
s.name = 'logstash-output-logservice'
|
3
|
-
s.version = "0.
|
3
|
+
s.version = "0.2.0"
|
4
4
|
s.licenses = ['Apache License (2.0)']
|
5
5
|
s.summary = "put data into logservice."
|
6
6
|
s.description = "This gem is a logstash plugin required to be installed on top of the Logstash core pipeline using $LS_HOME/bin/plugin install gemname. This gem is not a stand-alone program"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: logstash-output-logservice
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- tangkai
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-02-
|
11
|
+
date: 2016-02-29 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: logstash-core
|