unicorn-camilo 4.8.2.5.16 → 4.8.2.5.17

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: 973aaf53c3fe721fa73b579f187128bc7e491f88
4
- data.tar.gz: c6a29a015bcfc20630721265c7aa17958fe28f29
3
+ metadata.gz: 977f4f9c4d25a78b1b84eb604168414d489ac1c5
4
+ data.tar.gz: 5b2a267b817876a1a78333301be78a24c1d02a23
5
5
  SHA512:
6
- metadata.gz: 017b388610cec22ce05575d4a7fc4da23ee0c4632b09ccc86669ff7267c16684ce8dd599b9058203231f85116e659d75172164ff906ce9f90d423024f3beadea
7
- data.tar.gz: 69c4e26cf75ea7038dec7ed35f6d235c2b05fe7ccc52a3368b9edf0fcbf3dbaf4c7f7c9f24ef6c70287e0d56a668c8cc5a021fb7403f21309931a78033ff24c1
6
+ metadata.gz: 7156259613cd2729a25d3d21c49ea7e3d4213798b9a97b33d35e21a6185ecefe00fa0882da72cc583967f28ca1d6960bcb20519d7ab885766ffa6d0f7cd4688d
7
+ data.tar.gz: ba09f8497bc990b85af49fcd860034c23eca2077821e0c7d7f212c165f6499289eee774f3ebfc6ff2e53e216a7c887f7bc66389d3fe243da1b7d81f0c31d349d
@@ -177,7 +177,21 @@ class Unicorn::Configurator
177
177
  # with SIGKILL, the point of this callback is NOT to prevent killing
178
178
  # but to provide an instrumentation hook
179
179
  def before_murder(*args, &block)
180
- set_hook(:before_murder, block_given? ? block : args[0], 1)
180
+ set_hook_arg = if block_given?
181
+ # This hook is meant a an instrumentation point, it should not prevent the
182
+ # worker from getting killed exception will be logged and move on
183
+ new_block = Proc.new do
184
+ begin
185
+ block.call
186
+ rescue e
187
+ logger.error("Error trying to run before murder exception: #{e.name}")
188
+ end
189
+ end
190
+ else
191
+ args[0]
192
+ end
193
+
194
+ set_hook(:before_murder, set_hook_arg, 1)
181
195
  end
182
196
 
183
197
  # sets the timeout of worker processes to +seconds+. Workers
@@ -14,7 +14,7 @@ end.compact
14
14
 
15
15
  Gem::Specification.new do |s|
16
16
  s.name = %q{unicorn-camilo}
17
- s.version = "4.8.2.5.16"
17
+ s.version = "4.8.2.5.17"
18
18
  s.authors = ["#{name} hackers"]
19
19
  s.summary = summary
20
20
  s.date = Time.now.utc.strftime('%Y-%m-%d')
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: unicorn-camilo
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.8.2.5.16
4
+ version: 4.8.2.5.17
5
5
  platform: ruby
6
6
  authors:
7
7
  - Unicorn hackers
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-08-31 00:00:00.000000000 Z
11
+ date: 2014-11-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rack