unicorn 0.93.4 → 0.93.5

Sign up to get free protection for your applications and to get access to all the features.
data/GIT-VERSION-GEN CHANGED
@@ -1,7 +1,7 @@
1
1
  #!/bin/sh
2
2
 
3
3
  GVF=GIT-VERSION-FILE
4
- DEF_VER=v0.93.4.GIT
4
+ DEF_VER=v0.93.5.GIT
5
5
 
6
6
  LF='
7
7
  '
data/TODO CHANGED
@@ -1,3 +1,16 @@
1
1
  * Documentation improvements
2
2
 
3
- * launchers - add --kill switch to allow DRY pid file path definition
3
+ * ensure test suite passes on non-GNU/Linux systems
4
+ (likely that it already does)
5
+
6
+ * consider adding "working_directory" directive to Configurator
7
+ since START_CTX is ugly...
8
+
9
+ * consider adding user switching support (ugh...)
10
+ This makes more sense for Rainbows!, but some folks use it already...
11
+
12
+ * fix const-correctness in HTTP parser
13
+
14
+ * performance validation (esp. TeeInput)
15
+
16
+ * improve test suite (steal from Rainbows!, probably...)
data/lib/unicorn.rb CHANGED
@@ -277,6 +277,7 @@ module Unicorn
277
277
  # are trapped. See trap_deferred
278
278
  init_self_pipe!
279
279
  respawn = true
280
+ last_check = Time.now
280
281
 
281
282
  QUEUE_SIGS.each { |sig| trap_deferred(sig) }
282
283
  trap(:CHLD) { |sig_nr| awaken_master }
@@ -287,7 +288,11 @@ module Unicorn
287
288
  reap_all_workers
288
289
  case SIG_QUEUE.shift
289
290
  when nil
290
- murder_lazy_workers
291
+ # avoid murdering workers after our master process (or the
292
+ # machine) comes out of suspend/hibernation
293
+ if (last_check + timeout) >= (last_check = Time.now)
294
+ murder_lazy_workers
295
+ end
291
296
  maintain_worker_count if respawn
292
297
  master_sleep
293
298
  when :QUIT # graceful shutdown
@@ -475,7 +480,6 @@ module Unicorn
475
480
  kill_worker(:QUIT, wpid)
476
481
  next
477
482
  end
478
- stat.mode == 0100000 and next
479
483
  (diff = (Time.now - stat.ctime)) <= timeout and next
480
484
  logger.error "worker=#{worker.nr} PID:#{wpid} timeout " \
481
485
  "(#{diff}s > #{timeout}s), killing"
data/lib/unicorn/const.rb CHANGED
@@ -7,7 +7,7 @@ module Unicorn
7
7
  # gave about a 3% to 10% performance improvement over using the strings directly.
8
8
  # Symbols did not really improve things much compared to constants.
9
9
  module Const
10
- UNICORN_VERSION="0.93.4"
10
+ UNICORN_VERSION="0.93.5"
11
11
 
12
12
  DEFAULT_HOST = "0.0.0.0" # default TCP listen host address
13
13
  DEFAULT_PORT = 8080 # default TCP listen port
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: unicorn
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.93.4
4
+ version: 0.93.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Unicorn developers
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2009-10-27 00:00:00 -07:00
12
+ date: 2009-10-29 00:00:00 -07:00
13
13
  default_executable:
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency