scout_agent 3.2.1 → 3.2.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.
data/CHANGELOG CHANGED
@@ -1,3 +1,8 @@
1
+ == 3.2.2
2
+
3
+ * Fixed a bug where older versions of the standard timeout library could kill
4
+ the lifeline monitoring process
5
+
1
6
  == 3.2.1
2
7
 
3
8
  * Fixed a bug where log shifting failures could cause the agent to crash
@@ -151,6 +151,14 @@ module ScoutAgent
151
151
 
152
152
  # Module extensions for Process.
153
153
  module ProcessModule
154
+ #
155
+ # The error used to halt blocks in the loaded version of the Timeout
156
+ # library.
157
+ #
158
+ TimeoutStopError = Timeout.const_defined?(:ExitException) ?
159
+ Timeout::ExitException :
160
+ Timeout::Error
161
+
154
162
  #
155
163
  # A convenience method to ensure +child_pid+ is stopped. First a friendly
156
164
  # +TERM+ signal is sent. Then, after +pause+ seconds, +KILL+ will be sent
@@ -169,9 +177,9 @@ module ScoutAgent
169
177
  begin
170
178
  Timeout.timeout(pause) {
171
179
  begin
172
- return ::Process.wait2(child_pid).last # signal response
173
- rescue Exception => error # no such child
174
- raise if error.is_a? Timeout::ExitException # reraise timeouts
180
+ return ::Process.wait2(child_pid).last # signal response
181
+ rescue Exception => error # no such child
182
+ raise if error.is_a? TimeoutStopError # reraise timeouts
175
183
  return nil # we have already caught the child
176
184
  end
177
185
  }
data/lib/scout_agent.rb CHANGED
@@ -92,7 +92,7 @@ module ScoutAgent
92
92
  end
93
93
 
94
94
  # The version of this agent.
95
- VERSION = "3.2.1".freeze
95
+ VERSION = "3.2.2".freeze
96
96
  # A Pathname reference to the agent code directory, used in dynamic loading.
97
97
  LIB_DIR = Pathname.new(File.dirname(__FILE__)) + agent_name
98
98
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: scout_agent
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.2.1
4
+ version: 3.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - James Edward Gray II
@@ -12,7 +12,7 @@ autorequire:
12
12
  bindir: bin
13
13
  cert_chain: []
14
14
 
15
- date: 2009-05-26 00:00:00 -05:00
15
+ date: 2009-05-27 00:00:00 -05:00
16
16
  default_executable:
17
17
  dependencies:
18
18
  - !ruby/object:Gem::Dependency