logstash-output-statsd 2.0.1 → 2.0.2

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: 3b9c0fe499eb01a28f6cfb5a2c48cc8a1acb46fa
4
- data.tar.gz: ada26b5072c5709fb1f0557b3985871fc9e8abb8
3
+ metadata.gz: dc8eaa6df1f52dd72cb217325f1962c517b52dc7
4
+ data.tar.gz: 0120c9fd7f50334c2b061e2a71c64bd8135ed5ea
5
5
  SHA512:
6
- metadata.gz: 24cfe1fba3ba45495f012acaea69d516763f2df75e758ff51814fe168b30ca29ff7a3497e8e7a20b684e1464dd8500d3c0e3fd0ed4e868d885273669ef7db31a
7
- data.tar.gz: 989b8859fcc5d9da0f908899de5dec257fafa65b4ae95d7b3ea6965ea5c0be3e5fa9728f457bb08d9b9baba6b1f9698d0851e3f96e23b872afdccf3e6ef194a4
6
+ metadata.gz: 7e99f374bba25a94da85f612ef10f5f2be0ab0e628e799446027ad4296ee642ab878b0dbb7cc5f5e415cb60e48d27ba10719734e59079d3d5463ec262e93b1fd
7
+ data.tar.gz: 8c4f1dac3a06802b0cb0d916e2c841c3e3e21946dc36bd3bb1a41f1d4dccdbaffc3bbe1ef38d8b0d926205e195d61607c0c536e5baac76396028a80b66cc3acd
data/CHANGELOG.md CHANGED
@@ -1,3 +1,5 @@
1
+ ## 2.0.2
2
+ - Avoid rspec.configure global after and before :all blocks
1
3
  ## 2.0.0
2
4
  - Plugins were updated to follow the new shutdown semantic, this mainly allows Logstash to instruct input plugins to terminate gracefully,
3
5
  instead of using Thread.raise on the plugins' threads. Ref: https://github.com/elastic/logstash/pull/3895
@@ -1,7 +1,7 @@
1
1
  Gem::Specification.new do |s|
2
2
 
3
3
  s.name = 'logstash-output-statsd'
4
- s.version = '2.0.1'
4
+ s.version = '2.0.2'
5
5
  s.licenses = ['Apache License (2.0)']
6
6
  s.summary = "Send metrics to StatsD"
7
7
  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"
@@ -5,7 +5,12 @@ require_relative "../spec_helper"
5
5
  describe LogStash::Outputs::Statsd do
6
6
 
7
7
  let(:host) { "localhost" }
8
- let(:port) { @server.port }
8
+ let(:port) { rand(2000..10000) }
9
+ let!(:server) { StatsdServer.new.run(port) }
10
+
11
+ after(:each) do
12
+ server.close
13
+ end
9
14
 
10
15
  describe "registration and close" do
11
16
 
@@ -38,7 +43,7 @@ describe LogStash::Outputs::Statsd do
38
43
 
39
44
  it "should receive data send to the server" do
40
45
  subject.receive(event)
41
- expect(@server.received).to include("logstash.spec.foo.bar:0.1|c")
46
+ expect(server.received).to include("logstash.spec.foo.bar:0.1|c")
42
47
  end
43
48
 
44
49
  end
data/spec/spec_helper.rb CHANGED
@@ -46,24 +46,6 @@ class StatsdServer
46
46
 
47
47
  end
48
48
 
49
- module StatdHelpers
50
-
51
- def random_port
52
- rand(2000..10000)
53
- end
54
-
55
- end
56
-
57
49
  RSpec.configure do |c|
58
-
59
- c.include StatdHelpers
60
-
61
- c.before(:all) do
62
- srand(c.seed)
63
- @server = StatsdServer.new.run(random_port)
64
- end
65
-
66
- c.after(:all) do
67
- @server.close
68
- end
50
+ srand(c.seed)
69
51
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: logstash-output-statsd
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.1
4
+ version: 2.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Elastic
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-10-08 00:00:00.000000000 Z
11
+ date: 2015-10-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  requirement: !ruby/object:Gem::Requirement