aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Heinemeier Hansson <david@loudthinking.com>2005-07-19 18:53:48 +0000
committerDavid Heinemeier Hansson <david@loudthinking.com>2005-07-19 18:53:48 +0000
commit7077d8bb3d71742d5130753816508ccf302d7b26 (patch)
tree34d3d851ed3ad587923a2d61f0010acb07f62ade
parent42723e3a0c74e25c45c0f763740a3115302da4ac (diff)
downloadrails-7077d8bb3d71742d5130753816508ccf302d7b26.tar.gz
rails-7077d8bb3d71742d5130753816508ccf302d7b26.tar.bz2
rails-7077d8bb3d71742d5130753816508ccf302d7b26.zip
Dropped the 'immediate close-down' of FCGI processes since it didn't work consistently and produced bad responses when it didn't. So now a TERM ensures exit after the next request (just as if the process is handling a request when it receives the signal). This means that you'll have to 'nudge' all FCGI processes with a request in order to ensure that they have all reloaded. This can be done by something like ./script/process/repear --nudge 'http://www.myapp.com' --instances 10, which will load the myapp site 10 times (and thus hit all of the 10 FCGI processes once, enough to shut down).
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1867 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
-rw-r--r--activesupport/CHANGELOG4
-rw-r--r--railties/CHANGELOG5
-rw-r--r--railties/lib/fcgi_handler.rb14
3 files changed, 9 insertions, 14 deletions
diff --git a/activesupport/CHANGELOG b/activesupport/CHANGELOG
index 51abed18d9..cd8896ade9 100644
--- a/activesupport/CHANGELOG
+++ b/activesupport/CHANGELOG
@@ -1,11 +1,11 @@
*SVN*
+* Added stripping of _id to String#humanize, so "employee_id" becomes "Employee" #1574 [Justin French]
+
* Factor Fixnum and Bignum extensions into Integer extensions [Nicholas Seckar]
* Hooked #ordinalize into Fixnum and Bignum classes. [Nicholas Seckar, danp]
-* Added stripping of _id to humanize, so "employee_id" becomes "Employee" #1574 [Justin French]
-
* Added Fixnum#ordinalize to turn 1.ordinalize to "1st", 3.ordinalize to "3rd", and 10.ordinalize to "10th" and so on #1724 [paul@cnt.org]
diff --git a/railties/CHANGELOG b/railties/CHANGELOG
index 864cc3e2cd..fcef50e3d9 100644
--- a/railties/CHANGELOG
+++ b/railties/CHANGELOG
@@ -1,3 +1,8 @@
+*SVN*
+
+* Dropped the 'immediate close-down' of FCGI processes since it didn't work consistently and produced bad responses when it didn't. So now a TERM ensures exit after the next request (just as if the process is handling a request when it receives the signal). This means that you'll have to 'nudge' all FCGI processes with a request in order to ensure that they have all reloaded. This can be done by something like ./script/process/repear --nudge 'http://www.myapp.com' --instances 10, which will load the myapp site 10 times (and thus hit all of the 10 FCGI processes once, enough to shut down).
+
+
*0.13.1* (11 July, 2005)
* Look for app-specific generators in RAILS_ROOT/generators rather than the clunky old RAILS_ROOT/script/generators. Nobody really uses this feature except for the unit tests, so it's a negligible-impact change. If you want to work with third-party generators, drop them in ~/.rails/generators or simply install gems.
diff --git a/railties/lib/fcgi_handler.rb b/railties/lib/fcgi_handler.rb
index f2455b01c9..1e3061fe49 100644
--- a/railties/lib/fcgi_handler.rb
+++ b/railties/lib/fcgi_handler.rb
@@ -10,7 +10,6 @@ class RailsFCGIHandler
}
attr_reader :when_ready
- attr_reader :processing
attr_accessor :log_file_path
attr_accessor :gc_request_period
@@ -28,7 +27,6 @@ class RailsFCGIHandler
# takes this instance as an argument for further configuration.
def initialize(log_file_path = nil, gc_request_period = nil)
@when_ready = nil
- @processing = false
self.log_file_path = log_file_path || "#{RAILS_ROOT}/log/fastcgi.crash.log"
self.gc_request_period = gc_request_period
@@ -125,13 +123,8 @@ class RailsFCGIHandler
end
def graceful_exit_handler(signal)
- if processing
- dispatcher_log :info, "asked to terminate ASAP"
- @when_ready = :exit
- else
- dispatcher_log :info, "told to terminate NOW"
- exit
- end
+ dispatcher_log :info, "asked to terminate ASAP"
+ @when_ready = :exit
end
def reload_handler(signal)
@@ -140,13 +133,10 @@ class RailsFCGIHandler
end
def process_request(cgi)
- @processing = true
Dispatcher.dispatch(cgi)
rescue Object => e
raise if SignalException === e
dispatcher_error(e)
- ensure
- @processing = false
end
def mark!