logstash-input-beats 2.1.2 → 2.1.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 3394e299d7c7ecf132134ebed27de22b49d2bdc2
4
- data.tar.gz: 3e92f0bdb6b00a5d28955673a647099dfe905d4e
3
+ metadata.gz: 6b827272694308645c0341eae3bd6ee1caa6429a
4
+ data.tar.gz: 1128ffe70105c3c226da35bdf9b73615000c5feb
5
5
  SHA512:
6
- metadata.gz: 3e2456b1703cf75ab2724fa61014d8dc0e1b56bdaf05045ab06bef319f0511a99de7627bb581c39e2296d9468c7f2399a770c2c59f115de6a7353b0cfca46605
7
- data.tar.gz: 3ce48912d957e5539ba445b0580ef7e312f0d57b961a40247146fbf63d72778a2035bbb1ed25ceb0f3904b5ff4c06d7cb20373961a926d3a36161fcf7f503289
6
+ metadata.gz: 18e3f4fea0b3324bcabd32f54d0ee34fcc0c11547f1f9b26a807f5e6854f9888b9f9fafb91283572f1abadd3ef136fab60764d8566bfa418b90cc5937abe0d44
7
+ data.tar.gz: 0f3821b6baad697b89183418141d82134f208e4b38865433f40ac2b104f23df2f2e717bf34f90ff496ee4dbfdfde0bd14de4df86e0303b0181034779a229a27f
data/CHANGELOG.md CHANGED
@@ -1,3 +1,5 @@
1
+ # 2.1.3
2
+ - Make sure we stop all the threads after running the tests #48
1
3
  # 2.1.2
2
4
  - Catch the `java.lang.InterruptedException` in the events broker
3
5
  - Give a bit more time to the Thread to be started in the test #42
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = "logstash-input-beats"
3
- s.version = "2.1.2"
3
+ s.version = "2.1.3"
4
4
  s.licenses = ["Apache License (2.0)"]
5
5
  s.summary = "Receive events using the lumberjack protocol."
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"
@@ -89,27 +89,33 @@ describe LogStash::Inputs::Beats do
89
89
  # Event if we dont mock the actual socket work
90
90
  # we have to call run because it will correctly setup the queues
91
91
  # instances variables
92
- t = Thread.new do
92
+ @t = Thread.new do
93
93
  plugin.run(pipeline_queue)
94
94
  end
95
95
 
96
- # Give a bit of time to the server to correctly
96
+ # Give a bit of time to the server to correctly
97
97
  # start the thread.
98
- sleep(1)
98
+ sleep(1)
99
99
  end
100
100
 
101
101
  after :each do
102
102
  plugin.stop
103
+ # I am forcing a kill on the thread since we are using a mock connection and we have not implemented
104
+ # all the blocking IO, joining the thread and waiting wont work..
105
+ # I want to remove all the blockings in a new version real soon.
106
+ # If we dont do this the thread can still be present in other tests causing this kind of issue:
107
+ # https://github.com/logstash-plugins/logstash-input-beats/issues/48
108
+ @t.kill rescue nil
103
109
  end
104
110
 
105
111
  context "when an exception occur" do
106
112
  let(:connection_handler) { LogStash::Inputs::BeatsSupport::ConnectionHandler.new(connection, plugin, buffer_queue) }
107
- before do
113
+ before do
108
114
  expect(LogStash::Inputs::BeatsSupport::ConnectionHandler).to receive(:new).with(any_args).and_return(connection_handler)
109
115
  end
110
116
 
111
117
  it "calls flush on the handler and tag the events" do
112
- # try multiples times to make sure the
118
+ # try multiples times to make sure the
113
119
  # thread containing the `#run` is correctly started.
114
120
  try do
115
121
  expect(connection_handler).to receive(:accept) { raise LogStash::Inputs::Beats::InsertingToQueueTakeTooLong }
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: logstash-input-beats
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.2
4
+ version: 2.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Elastic
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-01-12 00:00:00.000000000 Z
11
+ date: 2016-02-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: logstash-core