logstash-output-sentry 0.3.1 → 0.4.1

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 54c19ff3430ad6d13ff04e3c2e5a58a30c6ad287
4
- data.tar.gz: cf9c838f8a464bdccd64b2e17dfbb54291f85909
3
+ metadata.gz: d73e9557eb60015f472332b61f32e288f4f8b9a4
4
+ data.tar.gz: 6dcfda94126f45d97dfca5871f2612f99c8c08c9
5
5
  SHA512:
6
- metadata.gz: 813f2ee9004e7ce6dff127d48965182f27a6847d7612718f86db8df653f405f10456bbe6504447d38ebe2d706d19f051a69bee264636244621955aa07ca83621
7
- data.tar.gz: 7323fd8ddfa2141e1e40cb9b348765918c2b9513b79a7c7bc1e62ec913261cd4744e2c2c63ea9f38d69b7ec83bb0aae7a67bbedfba3dd3de16289ea35f49d1dc
6
+ metadata.gz: a70cb4ed11f81caeb9fdbc6d8648ab961c5ca41a04b27a66e54288c9b110f56e6e3923737a8931cca4acb4889a9d7d1365a8765a126798d61725b343e6123947
7
+ data.tar.gz: 86887aa98d9a6b328647c6d4e8b6bf16dc36a89ca11fde27fa1cfad655d564fbaaa187e901cd7f23f5ca94db3dffeb886cc4ca0c77522d4eac58cb42a83cb005
data/CHANGELOG.md CHANGED
@@ -1,7 +1,16 @@
1
+ # Changelog
2
+
3
+ ## 0.4.1
4
+ - Fixing versions for development dependencies.
5
+
6
+ ## 0.4.0
7
+ - Implements the full sentry interface.
8
+
1
9
  ## 0.2.0
2
10
  - Improving sentry.rb script based on antho31/logstash-output-sentry and bigpandaio/logstash-output-sentry projects.
3
11
  - Creating documentation (starting from bigpandaio/logstash-output-sentry with some fixes for the differences that we have introduced to the code).
12
+
4
13
  ## 0.1.0
5
- - Starting project from clarkdave/logstash-sentry.rb
14
+ - Starting project from clarkdave/logstash-sentry.rb.
6
15
  - Packing script in a gem so it can be easily installed.
7
16
  - Adding parameters so that we can use the plugin to send data to our own sentry server.
data/CONTRIBUTORS CHANGED
@@ -1,10 +1,11 @@
1
1
  The following is a list of people who have contributed ideas, code, bug
2
- reports, or in general have helped logstash along its way.
2
+ reports, or in general have helped this plugin along its way.
3
3
 
4
4
  Contributors:
5
5
  * Javier Matos Odut (javiermatos)
6
+ # Julian Rüth (saraedum)
6
7
 
7
- Note: If you've sent us patches, bug reports, or otherwise contributed to
8
- Logstash, and you aren't on the list above and want to be, please let us know
9
- and we'll make sure you're here. Contributions from folks like you are what make
8
+ Note: If you've sent us patches, bug reports, or otherwise contributed to this
9
+ plugin, and you aren't on the list above and want to be, please let us know and
10
+ we'll make sure you're here. Contributions from folks like you are what make
10
11
  open source awesome.
data/LICENSE CHANGED
@@ -1,5 +1,3 @@
1
- Copyright (c) 2012–2015 Elasticsearch <http://www.elastic.co>
2
-
3
1
  Licensed under the Apache License, Version 2.0 (the "License");
4
2
  you may not use this file except in compliance with the License.
5
3
  You may obtain a copy of the License at
data/README.md CHANGED
@@ -18,7 +18,7 @@ You must have [Logstash](https://github.com/elasticsearch/logstash) installed fo
18
18
  As this plugin has been shared on [RubyGems](https://rubygems.org) with the name [logstash-output-sentry](https://rubygems.org/gems/logstash-output-sentry) you can install it using the following command from your Logstash installation path:
19
19
 
20
20
  ```sh
21
- bin/plugin install logstash-output-sentry
21
+ bin/logstash-plugin install logstash-output-sentry
22
22
  ```
23
23
 
24
24
  When installing from official repository as suggested below, the installation path is `/opt/logstash`.
@@ -34,70 +34,48 @@ It fits somewhere in-between a simple metrics solution (such as Graphite) and a
34
34
  [http|https]://[key]:[secret]@[host]/[project_id]
35
35
  ```
36
36
 
37
- * In your Logstash configuration file, inform your client key:
37
+ * Setup logstash to write to sentry:
38
38
  ```ruby
39
39
  output {
40
40
  sentry {
41
41
  'key' => "yourkey"
42
- 'secret' => "yoursecretkey"
42
+ 'secret' => "yoursecret"
43
43
  'project_id' => "yourprojectid"
44
44
  }
45
45
  }
46
46
  ```
47
47
 
48
- * Note that all your fields (incluing the Logstash field `message`) will be in the `extra` field in Sentry. But be careful: by default, the `host` is set to `"app.getsentry.com"`. If you have installed Sentry on your own machine, please change the `host` (change "localhost:9000" with the correct value according your configuration):
48
+ * By default, the plugin connects to https://app.getsentry.com/api. Set the `url` if you have installed Sentry on your own machine:
49
49
  ```ruby
50
50
  output {
51
51
  sentry {
52
- 'host' => "localhost:9000"
53
- 'use_ssl' => false
54
- 'project_id' => "yourprojectid"
52
+ 'url' => "http://local.sentry:9000/api"
55
53
  'key' => "yourkey"
56
- 'secret' => "yoursecretkey"
54
+ 'secret' => "yoursecret"
55
+ 'project_id' => "yourprojectid"
57
56
  }
58
57
  }
59
58
  ```
60
59
 
61
- * You can change the `message` field (default: `"Message from logstash"`), or optionally specify a field to use from your event. In case the `message` field doesn't exist, it'll be used as the actual message.
62
- ```ruby
63
- sentry {
64
- 'project_id' => "1"
65
- 'key' => "87e60914d35a4394a69acc3b6d15d061"
66
- 'secret' => "596d005d20274474991a2fb8c33040b8"
67
- 'msg' => "msg_field"
68
- }
69
- ```
60
+ * If you don't configure anything else, the necessary fields will be set automatically, i.e., `event_id`, `timestamp` (set to `@timestamp`), `logger` (set to `"logstash"`) and `platform` (set to `"other"`). All the other fields from logstash are going to be put into the `extra` field in sentry. Additionally, the `level` is set to `"error"` and the `server_name` to the value of `host`.
70
61
 
71
- * You can indicate the level (default: `"error"`), and decide if all your Logstash fields will be tagged in Sentry. If you use the protocole HTTPS, please enable `use_ssl` (default: `true`), but if you use http you MUST disable SSL.
62
+ * The plugin can write to all the fields that the sentry interface currently supports, i.e., `timestamp`, `message`, `logger`, `platform`, `sdk`, `level`, `culprit`, `server_name`, `release`, `tags`, `environment`, `modules`, `extra`, `fingerprint`, `exception`, `sentry.interface.Message`, `stacktrace`, `template`, `breadcrumbs`, `contexts`, `request`, `threads`, `user`, `debug_meta`, `repos`, `sdk`. To set a field, you can either read the value from another field or set it to a constant value by setting the corresponding `_value`:
72
63
  ```ruby
73
- sentry {
74
- 'host' => "192.168.56.102:9000"
75
- 'use_ssl' => false
76
- 'project_id' => "1"
77
- 'key' => "87e60914d35a4394a69acc3b6d15d061"
78
- 'secret' => "596d005d20274474991a2fb8c33040b8"
79
- 'msg' => "Message you want"
80
- 'level_tag' => "fatal"
81
- 'fields_to_tags' => true
82
- }
83
- ```
64
+ output {
65
+ sentry {
66
+ 'message' => "message" # sets message to the contents of the message field
67
+ 'environment' => "[tag][Environment]" # sets message to the contents of the field Environment in tag
68
+ 'exception' => "[@metadata][sentry][exception]" # sets exception to the metadata field, see below for a complete example
69
+ 'user_value' => "nobody" # sets the user to the constant "nobody"
84
70
 
85
- * You can optionally strip the timestamp from the sentry title by setting `strip_timestamp` field to `true` (default: `false`), which will change `YYYY-MM-DD HH:MM:SS,MILLISEC INFO ..` to `INFO ...`
86
- ```ruby
87
- sentry {
88
- 'host' => "192.168.56.102:9000"
89
- 'use_ssl' => false
90
- 'project_id' => "1"
91
- 'key' => "87e60914d35a4394a69acc3b6d15d061"
92
- 'secret' => "596d005d20274474991a2fb8c33040b8"
93
- 'msg' => "Message you want"
94
- 'level_tag' => "fatal"
95
- 'fields_to_tags' => true
96
- 'strim_timestamp' => true
71
+ 'key' => "yourkey"
72
+ 'secret' => "yoursecret"
73
+ 'project_id' => "yourprojectid"
74
+ }
97
75
  }
98
76
  ```
99
77
 
100
- * You can also set the project id, key, level tag, and secret in a filter to allow for a cleaner dynamic config
78
+ * You can also prepare the settings in a filter to create a cleaner config:
101
79
  ```ruby
102
80
  input {
103
81
  syslog {
@@ -154,17 +132,13 @@ filter {
154
132
  }
155
133
  }
156
134
  output {
157
- elasticsearch {
158
- hosts => ["192.168.1.200:9200"]
159
- document_type => "%{type}"
160
- }
161
135
  sentry {
162
- fields_to_tags => true
163
- host => "%{[@metadata][sentry][host]}"
164
- key => "%{[@metadata][sentry][key]}"
165
- level_tag => "%{[@metadata][sentry][severity]}"
166
- msg => "[@metadata][sentry][msg]"
136
+ server_name => "[@metadata][sentry][host]"
137
+ level => "[@metadata][sentry][severity]"
138
+ message => "[@metadata][sentry][msg]"
139
+
167
140
  project_id => "%{[@metadata][sentry][pid]}"
141
+ key => "%{[@metadata][sentry][key]}"
168
142
  secret => "%{[@metadata][sentry][secret]}"
169
143
  }
170
144
  }
@@ -174,4 +148,4 @@ output {
174
148
 
175
149
  All contributions are welcome: ideas, patches, documentation, bug reports, complaints, and even something you drew up on a napkin.
176
150
 
177
- Note that this plugin has been written from [this Dave Clark's Gist](https://gist.github.com/clarkdave/edaab9be9eaa9bf1ee5f).
151
+ Note that this plugin has been written from [this Gist](https://gist.github.com/clarkdave/edaab9be9eaa9bf1ee5f).
@@ -3,145 +3,148 @@ require 'logstash/outputs/base'
3
3
  require 'logstash/namespace'
4
4
  require 'json'
5
5
 
6
- # Sentry is a modern error logging and aggregation platform.
7
- # * https://getsentry.com/
8
- #
9
- # It’s important to note that Sentry should not be thought of as a log stream, but as an aggregator.
10
- # It fits somewhere in-between a simple metrics solution (such as Graphite) and a full-on log stream aggregator (like Logstash).
11
- #
12
- # Generate and inform your client key (Settings -> Client key)
13
- # The client key has this form * https://[key]:[secret]@[host]/[project_id] *
14
- #
15
- # More informations :
16
- # * https://sentry.readthedocs.org/en/latest/
17
-
18
-
19
6
  class LogStash::Outputs::Sentry < LogStash::Outputs::Base
20
-
21
7
  config_name 'sentry'
8
+ concurrency :shared
22
9
 
23
- # Whether to use SSL (https) or not (http)
24
- config :use_ssl, :validate => :boolean, :required => false, :default => true
25
-
26
- # Sentry host
27
- config :host, :validate => :string, :required => true, :default => 'app.getsentry.com'
10
+ # Sentry API URL
11
+ config :url, :validate => :uri, :required => false, :default => 'https://app.getsentry.com/api'
28
12
 
29
13
  # Project id, key and secret
30
14
  config :project_id, :validate => :string, :required => true
31
15
  config :key, :validate => :string, :required => true
32
16
  config :secret, :validate => :string, :required => true
33
17
 
34
- # This sets the message value in Sentry (the title of your event)
35
- config :msg, :validate => :string, :default => 'Message from logstash', :required => false
36
-
37
- # This sets the level value in Sentry (the level tag), allow usage of event dynamic value
38
- config :level_tag, :validate => :string, :default => 'error'
39
-
40
- # If set to true automatically map all logstash defined fields to Sentry extra fields.
41
- # As an example, the logstash event:
42
- # [source,ruby]
43
- # {
44
- # "@timestamp": "2013-12-10T14:36:26.151+0000",
45
- # "@version": 1,
46
- # "message": "log message",
47
- # "host": "host.domain.com",
48
- # "nested_field": {
49
- # "key": "value"
50
- # }
51
- # }
52
- # Is mapped to this Sentry event:
53
- # [source,ruby]
54
- # extra {
55
- # "@timestamp": "2013-12-10T14:36:26.151+0000",
56
- # "@version": 1,
57
- # "message": "log message",
58
- # "host": "host.domain.com",
59
- # "nested_field": {
60
- # "key": "value"
61
- # }
62
- # }
63
- config :fields_to_tags, :validate => :boolean, :default => false, :required => false
64
-
65
- # Remove timestamp from message (title) if the message starts with a timestamp
66
- config :strip_timestamp, :validate => :boolean, :default => false, :required => false
67
-
68
- public
69
- def register
70
- #I took this out becuase it fails when I try sending in the project_id or host as part of the event for a dynamic config
71
- # require 'net/https'
72
- # require 'uri'
18
+ def self.sentry_key(name, field_default=nil, value_default=nil)
19
+ name = name.to_s if name.is_a?(Symbol)
73
20
 
74
- # @url = "%{proto}://#{host}/api/#{project_id}/store/" % { :proto => use_ssl ? 'https' : 'http' }
75
- # @uri = URI.parse(@url)
21
+ @sentry_keys ||= []
22
+ @sentry_keys << name
76
23
 
77
- # @client = Net::HTTP.new(@uri.host, @uri.port)
78
- # @client.use_ssl = use_ssl
79
- # @client.verify_mode = OpenSSL::SSL::VERIFY_NONE
24
+ opts = {
25
+ :validate => :string,
26
+ :required => false,
27
+ }
80
28
 
81
- # @logger.debug('Client', :client => @client.inspect)
29
+ config name, opts.merge(if field_default then {:default => field_default} else {} end)
30
+ config "#{name}_value", opts.merge(if value_default then {:default => value_default} else {} end)
82
31
  end
32
+ class << self; attr_accessor :sentry_keys end
33
+ # https://docs.sentry.io/clientdev/attributes/
34
+ sentry_key :timestamp, field_default='@timestamp'
35
+ sentry_key :message
36
+ sentry_key :_logger
37
+ sentry_key :platform
38
+ sentry_key :sdk
39
+ sentry_key :level, value_default='error'
40
+ sentry_key :culprit
41
+ sentry_key :server_name, field_default='host'
42
+ sentry_key :release
43
+ sentry_key :tags
44
+ sentry_key :environment
45
+ sentry_key :modules
46
+ sentry_key :extra, field_default='' # puts all fields into extra
47
+ sentry_key :fingerprint
48
+ # https://docs.sentry.io/clientdev/interfaces/exception/
49
+ sentry_key :exception
50
+ # https://docs.sentry.io/clientdev/interfaces/message/
51
+ sentry_key :"sentry.interfaces.Message"
52
+ # https://docs.sentry.io/clientdev/interfaces/stacktrace/
53
+ sentry_key :stacktrace
54
+ # https://docs.sentry.io/clientdev/interfaces/template/
55
+ sentry_key :template
56
+ # https://docs.sentry.io/clientdev/interfaces/breadcrumbs/
57
+ sentry_key :breadcrumbs
58
+ # https://docs.sentry.io/clientdev/interfaces/contexts/
59
+ sentry_key :contexts
60
+ # https://docs.sentry.io/clientdev/interfaces/http/
61
+ sentry_key :request
62
+ # https://docs.sentry.io/clientdev/interfaces/threads/
63
+ sentry_key :threads
64
+ # https://docs.sentry.io/clientdev/interfaces/user/
65
+ sentry_key :user
66
+ # https://docs.sentry.io/clientdev/interfaces/debug/
67
+ sentry_key :debug_meta
68
+ # https://docs.sentry.io/clientdev/interfaces/repos/
69
+ sentry_key :repos
70
+ # https://docs.sentry.io/clientdev/interfaces/sdk/
71
+ sentry_key :sdk
83
72
 
84
73
  public
85
- def receive(event)
86
- require 'net/https'
87
- require 'uri'
88
-
89
- url = "%{proto}://#{event.sprintf(@host)}/api/#{event.sprintf(@project_id)}/store/" % { :proto => use_ssl ? 'https' : 'http' }
90
- uri = URI.parse(url)
74
+ def register
75
+ end
91
76
 
92
- client = Net::HTTP.new(uri.host, uri.port)
93
- client.use_ssl = use_ssl
94
- client.verify_mode = OpenSSL::SSL::VERIFY_NONE
77
+ def get(event, key)
78
+ key = key.to_s if key.is_a?(Symbol)
95
79
 
96
- @logger.debug('Client', :client => client.inspect)
80
+ instance_variable_name = key.gsub(/\./, '')
97
81
 
98
- return unless output?(event)
82
+ field = instance_variable_get("@#{instance_variable_name}")
83
+ if field == ''
84
+ ret = event.to_hash
85
+ ret.delete('tags')
86
+ return ret
87
+ elsif field
88
+ return event.get(field) if event.get(field)
89
+ end
99
90
 
100
- require 'securerandom'
91
+ value = instance_variable_get("@#{instance_variable_name}_value")
92
+ return value # can be nil
93
+ end
101
94
 
102
- #use message from event if exists, if not from static
103
- message_to_send = event["#{msg}"] || "#{msg}"
104
- if strip_timestamp
105
- #remove timestamp from message if available
106
- message_matched = message_to_send.match(/\d\d\d\d\-\d\d\-\d\d\s[0-9]{1,2}\:\d\d\:\d\d,\d{1,}\s(.*)/)
107
- message_to_send = message_matched ? message_matched[1] : message_to_send
95
+ def multi_receive(events)
96
+ for event in events
97
+ receive(event)
108
98
  end
99
+ end
100
+
101
+ def create_packet(event, timestamp)
102
+ require 'securerandom'
103
+ event_id = SecureRandom.uuid.gsub('-', '')
109
104
 
110
105
  packet = {
111
- :event_id => SecureRandom.uuid.gsub('-', ''),
112
- :timestamp => event['@timestamp'],
113
- :message => message_to_send,
114
- :level => event.sprintf(@level_tag),
115
- :platform => 'logstash',
116
- :server_name => event['host'],
117
- :extra => event.to_hash,
106
+ # parameters required by sentry
107
+ :event_id => event_id,
108
+ :timestamp => timestamp.to_s,
109
+ :logger => get(event, :_logger) || "logstash",
110
+ :platform => get(event, :platform) || "other",
118
111
  }
119
112
 
120
- if fields_to_tags
121
- packet[:tags] = event.to_hash
113
+ for key in LogStash::Outputs::Sentry.sentry_keys
114
+ sentry_key = key.gsub(/^_/,'')
115
+ next if packet[sentry_key];
116
+ value = get(event, key)
117
+ packet[sentry_key] = value if value
122
118
  end
123
119
 
124
- @logger.debug('Sentry packet', :sentry_packet => packet)
120
+ return packet
121
+ end
125
122
 
123
+ def send_packet(event, packet, timestamp)
126
124
  auth_header = "Sentry sentry_version=5," +
127
- "sentry_client=raven_logstash/1.0," +
128
- "sentry_timestamp=#{event['@timestamp'].to_i}," +
129
- "sentry_key=#{event.sprintf(@key)}," +
130
- "sentry_secret=#{event.sprintf(@secret)}"
131
-
132
- request = Net::HTTP::Post.new(uri.path)
125
+ "sentry_client=raven_logstash/0.4.0," +
126
+ "sentry_timestamp=#{timestamp.to_i}," +
127
+ "sentry_key=#{@key}," +
128
+ "sentry_secret=#{@secret}"
133
129
 
134
- begin
135
- request.body = packet.to_json
136
- request.add_field('X-Sentry-Auth', auth_header)
130
+ url = "#{@url}/#{@project_id}/store/"
137
131
 
138
- response = client.request(request)
132
+ require 'http'
133
+ response = HTTP.post(url, :body => packet.to_json, :headers => {:"X-Sentry-Auth" => auth_header})
134
+ raise "Sentry answered with #{response} and code #{response.code} to our request #{packet}" unless response.code == 200
135
+ end
139
136
 
140
- @logger.info('Sentry response', :request => request.inspect, :response => response.inspect)
137
+ def receive(event)
138
+ begin
139
+ require 'time'
140
+ timestamp = get(event, :timestamp) || Time.now
141
141
 
142
- raise unless response.code == '200'
142
+ sentry_packet = create_packet(event, timestamp)
143
+ @logger.debug('Sentry packet', :sentry_packet => sentry_packet)
144
+
145
+ send_packet(event, sentry_packet, timestamp)
143
146
  rescue Exception => e
144
- @logger.warn('Unhandled exception', :request => request.inspect, :response => response.inspect, :exception => e.inspect)
147
+ @logger.warn('Unhandled exception', :exception => e)
145
148
  end
146
149
  end
147
150
  end
@@ -1,25 +1,25 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'logstash-output-sentry'
3
- s.version = '0.3.1'
4
- s.licenses = ['Apache License (2.0)']
3
+ s.version = '0.4.1'
4
+ s.licenses = ['Apache-2.0']
5
5
  s.summary = 'This output plugin sends messages to any sentry server.'
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 logstash-output-sentry. This gem is not a stand-alone program.'
7
- s.authors = ['Javier Matos Odut']
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 logstash-output-sentry. This gem is not a stand-alone program.'
7
+ s.authors = ['Javier Matos Odut', 'Julian Rüth']
8
8
  s.email = 'iam@javiermatos.com'
9
9
  s.homepage = 'https://github.com/javiermatos/logstash-output-sentry'
10
10
  s.require_paths = ['lib']
11
11
 
12
12
  # Files
13
13
  s.files = Dir['lib/**/*','spec/**/*','vendor/**/*','*.gemspec','*.md','CONTRIBUTORS','Gemfile','LICENSE','NOTICE.TXT']
14
- # Tests
14
+ # Tests
15
15
  s.test_files = s.files.grep(%r{^(test|spec|features)/})
16
16
 
17
17
  # Special flag to let us know this is actually a logstash plugin
18
18
  s.metadata = { 'logstash_plugin' => 'true', 'logstash_group' => 'output' }
19
19
 
20
20
  # Gem dependencies
21
- s.add_runtime_dependency 'logstash-core', '>= 2.0.0', '< 3.0.0'
22
- s.add_runtime_dependency 'logstash-codec-plain'
23
- s.add_runtime_dependency 'json', '>=1.8.0', '< 2.0.0'
24
- s.add_development_dependency 'logstash-devutils'
21
+ s.add_runtime_dependency 'logstash-core-plugin-api', '>= 1.60', '< 3.0'
22
+ s.add_runtime_dependency 'json', '>= 1.8.0', '< 2.0.0'
23
+ s.add_development_dependency 'logstash-devutils', '>= 1.0.0', '< 2.0.0'
24
+ s.add_development_dependency 'logstash-codec-plain', '>= 3.0.0', '< 4.0.0'
25
25
  end
@@ -1,22 +1,21 @@
1
- # encoding: utf-8
2
1
  require 'logstash/devutils/rspec/spec_helper'
3
2
  require 'logstash/outputs/sentry'
4
- require 'logstash/codecs/plain'
5
- require 'logstash/event'
6
3
 
7
4
  describe LogStash::Outputs::Sentry do
8
- let(:sample_event) { LogStash::Event.new }
9
- let(:output) { LogStash::Outputs::Sentry.new }
5
+ describe "Registration" do
6
+ config <<-CONFIG
7
+ output {
8
+ sentry {
9
+ url => "http://web:9000/api"
10
+ project_id => "2"
11
+ key => "Sheez5ohZ8Ohdiquei2E"
12
+ secret => "vie4eituy2aYoongeege"
13
+ }
14
+ }
15
+ CONFIG
10
16
 
11
- before do
12
- output.register
13
- end
14
-
15
- describe 'receive message' do
16
- subject { output.receive(sample_event) }
17
-
18
- it 'returns a string' do
19
- expect(subject).to eq('Event received')
20
- end
17
+ sample("...") do
18
+ ;
19
+ end
21
20
  end
22
21
  end
metadata CHANGED
@@ -1,85 +1,98 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: logstash-output-sentry
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.1
4
+ version: 0.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Javier Matos Odut
8
+ - Julian Rüth
8
9
  autorequire:
9
10
  bindir: bin
10
11
  cert_chain: []
11
- date: 2016-05-25 00:00:00.000000000 Z
12
+ date: 2017-05-23 00:00:00.000000000 Z
12
13
  dependencies:
13
14
  - !ruby/object:Gem::Dependency
14
- name: logstash-core
15
+ name: logstash-core-plugin-api
15
16
  requirement: !ruby/object:Gem::Requirement
16
17
  requirements:
17
18
  - - ">="
18
19
  - !ruby/object:Gem::Version
19
- version: 2.0.0
20
+ version: '1.60'
20
21
  - - "<"
21
22
  - !ruby/object:Gem::Version
22
- version: 3.0.0
23
+ version: '3.0'
23
24
  type: :runtime
24
25
  prerelease: false
25
26
  version_requirements: !ruby/object:Gem::Requirement
26
27
  requirements:
27
28
  - - ">="
28
29
  - !ruby/object:Gem::Version
29
- version: 2.0.0
30
+ version: '1.60'
30
31
  - - "<"
31
32
  - !ruby/object:Gem::Version
32
- version: 3.0.0
33
+ version: '3.0'
33
34
  - !ruby/object:Gem::Dependency
34
- name: logstash-codec-plain
35
+ name: json
35
36
  requirement: !ruby/object:Gem::Requirement
36
37
  requirements:
37
38
  - - ">="
38
39
  - !ruby/object:Gem::Version
39
- version: '0'
40
+ version: 1.8.0
41
+ - - "<"
42
+ - !ruby/object:Gem::Version
43
+ version: 2.0.0
40
44
  type: :runtime
41
45
  prerelease: false
42
46
  version_requirements: !ruby/object:Gem::Requirement
43
47
  requirements:
44
48
  - - ">="
45
49
  - !ruby/object:Gem::Version
46
- version: '0'
50
+ version: 1.8.0
51
+ - - "<"
52
+ - !ruby/object:Gem::Version
53
+ version: 2.0.0
47
54
  - !ruby/object:Gem::Dependency
48
- name: json
55
+ name: logstash-devutils
49
56
  requirement: !ruby/object:Gem::Requirement
50
57
  requirements:
51
58
  - - ">="
52
59
  - !ruby/object:Gem::Version
53
- version: 1.8.0
60
+ version: 1.0.0
54
61
  - - "<"
55
62
  - !ruby/object:Gem::Version
56
63
  version: 2.0.0
57
- type: :runtime
64
+ type: :development
58
65
  prerelease: false
59
66
  version_requirements: !ruby/object:Gem::Requirement
60
67
  requirements:
61
68
  - - ">="
62
69
  - !ruby/object:Gem::Version
63
- version: 1.8.0
70
+ version: 1.0.0
64
71
  - - "<"
65
72
  - !ruby/object:Gem::Version
66
73
  version: 2.0.0
67
74
  - !ruby/object:Gem::Dependency
68
- name: logstash-devutils
75
+ name: logstash-codec-plain
69
76
  requirement: !ruby/object:Gem::Requirement
70
77
  requirements:
71
78
  - - ">="
72
79
  - !ruby/object:Gem::Version
73
- version: '0'
80
+ version: 3.0.0
81
+ - - "<"
82
+ - !ruby/object:Gem::Version
83
+ version: 4.0.0
74
84
  type: :development
75
85
  prerelease: false
76
86
  version_requirements: !ruby/object:Gem::Requirement
77
87
  requirements:
78
88
  - - ">="
79
89
  - !ruby/object:Gem::Version
80
- version: '0'
90
+ version: 3.0.0
91
+ - - "<"
92
+ - !ruby/object:Gem::Version
93
+ version: 4.0.0
81
94
  description: This gem is a logstash plugin required to be installed on top of the
82
- Logstash core pipeline using $LS_HOME/bin/plugin install logstash-output-sentry.
95
+ Logstash core pipeline using $LS_HOME/bin/logstash-plugin install logstash-output-sentry.
83
96
  This gem is not a stand-alone program.
84
97
  email: iam@javiermatos.com
85
98
  executables: []
@@ -88,17 +101,15 @@ extra_rdoc_files: []
88
101
  files:
89
102
  - CHANGELOG.md
90
103
  - CONTRIBUTORS
91
- - DEVELOPER.md
92
104
  - Gemfile
93
105
  - LICENSE
94
- - NOTICE.TXT
95
106
  - README.md
96
107
  - lib/logstash/outputs/sentry.rb
97
108
  - logstash-output-sentry.gemspec
98
109
  - spec/outputs/sentry_spec.rb
99
110
  homepage: https://github.com/javiermatos/logstash-output-sentry
100
111
  licenses:
101
- - Apache License (2.0)
112
+ - Apache-2.0
102
113
  metadata:
103
114
  logstash_plugin: 'true'
104
115
  logstash_group: output
@@ -118,7 +129,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
118
129
  version: '0'
119
130
  requirements: []
120
131
  rubyforge_project:
121
- rubygems_version: 2.5.1
132
+ rubygems_version: 2.5.2
122
133
  signing_key:
123
134
  specification_version: 4
124
135
  summary: This output plugin sends messages to any sentry server.
data/DEVELOPER.md DELETED
@@ -1 +0,0 @@
1
- # logstash-output-sentry
data/NOTICE.TXT DELETED
@@ -1,5 +0,0 @@
1
- Elasticsearch
2
- Copyright 2012-2015 Elasticsearch
3
-
4
- This product includes software developed by The Apache Software
5
- Foundation (http://www.apache.org/).