logstash-output-stomp 3.0.0 → 3.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +11 -3
- data/lib/logstash/outputs/stomp.rb +28 -5
- data/logstash-output-stomp.gemspec +1 -2
- metadata +20 -20
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1875f7a3580c8b16c6bab0d30044c4671515c664
|
4
|
+
data.tar.gz: a6a6fb370ec147d64c853db49caf0b44ce9ae235
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9dd6cd9e3e03d1fc89ae68bdf3ecb9c19b2591bd3d50d8c34dc25e58451bc6b4d94ecc6f24a42a4a5e2c98871343ee7d59aca6c02d07c6b3bb820c71b2305bcb
|
7
|
+
data.tar.gz: 7d3c67f56a4782eee3aeeb94afa03ef895b241ed546829e932173530b79751031b2ffd19e86a325cd8f2a52501053d9a155104e6d604c13863417ee8f92756c8
|
data/CHANGELOG.md
CHANGED
@@ -1,9 +1,17 @@
|
|
1
|
-
|
1
|
+
## 3.0.1
|
2
|
+
- Fix a data loss issue when shutting down logstash #8
|
3
|
+
- Move from receive to `multi_receive` api and send events per batch #9
|
4
|
+
- Allow to send custom header #3
|
5
|
+
|
6
|
+
## 3.0.0 (2016-05-20)
|
2
7
|
- Breaking: Updated to use new Java APIs
|
3
|
-
|
8
|
+
|
9
|
+
## 2.0.4
|
4
10
|
- Depend on logstash-core-plugin-api instead of logstash-core, removing the need to mass update plugins on major releases of logstash
|
5
|
-
|
11
|
+
|
12
|
+
## 2.0.3
|
6
13
|
- New dependency requirements for logstash-core for the 5.0 release
|
14
|
+
|
7
15
|
## 2.0.0
|
8
16
|
- Plugins were updated to follow the new shutdown semantic, this mainly allows Logstash to instruct input plugins to terminate gracefully,
|
9
17
|
instead of using Thread.raise on the plugins' threads. Ref: https://github.com/elastic/logstash/pull/3895
|
@@ -27,6 +27,12 @@ class LogStash::Outputs::Stomp < LogStash::Outputs::Base
|
|
27
27
|
# The vhost to use
|
28
28
|
config :vhost, :validate => :string, :default => nil
|
29
29
|
|
30
|
+
# Custom headers to send with each message. Supports string expansion, meaning
|
31
|
+
# %{foo} values will expand to the field value.
|
32
|
+
#
|
33
|
+
# Example: headers => ["amq-msg-type", "text", "host", "%{host}"]
|
34
|
+
config :headers, :validate => :hash
|
35
|
+
|
30
36
|
# Enable debugging output?
|
31
37
|
config :debug, :validate => :boolean, :default => false
|
32
38
|
|
@@ -57,11 +63,28 @@ class LogStash::Outputs::Stomp < LogStash::Outputs::Base
|
|
57
63
|
|
58
64
|
connect
|
59
65
|
end # def register
|
60
|
-
|
61
|
-
def receive(event)
|
62
|
-
|
63
66
|
|
64
|
-
|
65
|
-
|
67
|
+
public
|
68
|
+
def close
|
69
|
+
@logger.warn("Disconnecting from stomp broker")
|
70
|
+
@client.disconnect if @client.connected?
|
71
|
+
end # def close
|
72
|
+
|
73
|
+
def multi_receive(events)
|
74
|
+
|
75
|
+
headers = Hash.new
|
76
|
+
if @headers
|
77
|
+
@headers.each do |k,v|
|
78
|
+
headers[k] = event.sprintf(v)
|
79
|
+
end
|
80
|
+
end
|
81
|
+
|
82
|
+
@logger.debug(["stomp sending events in batch", { :host => @host, :events => events.length, :headers => headers }])
|
83
|
+
|
84
|
+
@client.transaction do |t|
|
85
|
+
events.each { |event|
|
86
|
+
t.send(event.sprintf(@destination), event.to_json, headers)
|
87
|
+
}
|
88
|
+
end
|
66
89
|
end # def receive
|
67
90
|
end # class LogStash::Outputs::Stomp
|
@@ -1,7 +1,6 @@
|
|
1
1
|
Gem::Specification.new do |s|
|
2
|
-
|
3
2
|
s.name = 'logstash-output-stomp'
|
4
|
-
s.version = '3.0.
|
3
|
+
s.version = '3.0.1'
|
5
4
|
s.licenses = ['Apache License (2.0)']
|
6
5
|
s.summary = "Send events to a stomp server"
|
7
6
|
s.description = "This gem is a Logstash plugin required to be installed on top of the Logstash core pipeline using $LS_HOME/bin/logstash-plugin install gemname. This gem is not a stand-alone program"
|
metadata
CHANGED
@@ -1,57 +1,57 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: logstash-output-stomp
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.0.
|
4
|
+
version: 3.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Elastic
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-06-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
|
-
name: logstash-core-plugin-api
|
15
|
-
version_requirements: !ruby/object:Gem::Requirement
|
16
|
-
requirements:
|
17
|
-
- - ~>
|
18
|
-
- !ruby/object:Gem::Version
|
19
|
-
version: '2.0'
|
20
14
|
requirement: !ruby/object:Gem::Requirement
|
21
15
|
requirements:
|
22
|
-
- - ~>
|
16
|
+
- - "~>"
|
23
17
|
- !ruby/object:Gem::Version
|
24
18
|
version: '2.0'
|
19
|
+
name: logstash-core-plugin-api
|
25
20
|
prerelease: false
|
26
21
|
type: :runtime
|
27
|
-
- !ruby/object:Gem::Dependency
|
28
|
-
name: onstomp
|
29
22
|
version_requirements: !ruby/object:Gem::Requirement
|
30
23
|
requirements:
|
31
|
-
- -
|
24
|
+
- - "~>"
|
32
25
|
- !ruby/object:Gem::Version
|
33
|
-
version: '0'
|
26
|
+
version: '2.0'
|
27
|
+
- !ruby/object:Gem::Dependency
|
34
28
|
requirement: !ruby/object:Gem::Requirement
|
35
29
|
requirements:
|
36
|
-
- -
|
30
|
+
- - ">="
|
37
31
|
- !ruby/object:Gem::Version
|
38
32
|
version: '0'
|
33
|
+
name: onstomp
|
39
34
|
prerelease: false
|
40
35
|
type: :runtime
|
41
|
-
- !ruby/object:Gem::Dependency
|
42
|
-
name: logstash-devutils
|
43
36
|
version_requirements: !ruby/object:Gem::Requirement
|
44
37
|
requirements:
|
45
|
-
- -
|
38
|
+
- - ">="
|
46
39
|
- !ruby/object:Gem::Version
|
47
40
|
version: '0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
48
42
|
requirement: !ruby/object:Gem::Requirement
|
49
43
|
requirements:
|
50
|
-
- -
|
44
|
+
- - ">="
|
51
45
|
- !ruby/object:Gem::Version
|
52
46
|
version: '0'
|
47
|
+
name: logstash-devutils
|
53
48
|
prerelease: false
|
54
49
|
type: :development
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - ">="
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0'
|
55
55
|
description: This gem is a Logstash plugin required to be installed on top of the Logstash core pipeline using $LS_HOME/bin/logstash-plugin install gemname. This gem is not a stand-alone program
|
56
56
|
email: info@elastic.co
|
57
57
|
executables: []
|
@@ -79,12 +79,12 @@ require_paths:
|
|
79
79
|
- lib
|
80
80
|
required_ruby_version: !ruby/object:Gem::Requirement
|
81
81
|
requirements:
|
82
|
-
- -
|
82
|
+
- - ">="
|
83
83
|
- !ruby/object:Gem::Version
|
84
84
|
version: '0'
|
85
85
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
86
86
|
requirements:
|
87
|
-
- -
|
87
|
+
- - ">="
|
88
88
|
- !ruby/object:Gem::Version
|
89
89
|
version: '0'
|
90
90
|
requirements: []
|