GitHub Sale: sign up for any paid plan this week and pay nothing until January 1, 2009!  [ hide ]

public
Fork of rails/rails
Description: Ruby on Rails
Homepage: http://rubyonrails.org
Clone URL: git://github.com/ddollar/rails.git
Added ActiveRecord::Base.clear_active_connections! in development mode so 
the database connection is not carried over from request to request. Some 
databases won't reread the schema if that doesn't happen (I'm looking at 
you SQLite), so you have to restart the server after each migration (= no 
fun) [DHH]

git-svn-id: 
http://svn-commit.rubyonrails.org/rails/branches/1-2-pre-release@5617 
5ecf4fe2-1ee6-0310-87b1-e25e094e27de
dhh (author)
Wed Nov 22 21:16:44 -0800 2006
commit  143d54893fac35bbdf644c41f0eb8a6668ddd52c
tree    1f6ac108a23dcefadd337c9f583de491e054f729
parent  82e5ff7c6ea6ff516cfc8d7ed7b18c128d7d50d4
...
1
2
 
 
3
4
5
...
1
2
3
4
5
6
7
0
@@ -1,5 +1,7 @@
0
 *1.2.0 RC1* (November 22nd, 2006)
0
 
0
+* Added ActiveRecord::Base.clear_active_connections! in development mode so the database connection is not carried over from request to request. Some databases won't reread the schema if that doesn't happen (I'm looking at you SQLite), so you have to restart the server after each migration (= no fun) [DHH]
0
+
0
 * Made RAILS_GEM_VERSION work for beta gems too, so specifying 1.1.6 will give you 1.1.6.4520 if available [DHH]
0
 
0
 * Update to Prototype and script.aculo.us [5579]. [Sam Stephenson, Thomas Fuchs]
...
55
56
57
58
 
 
 
 
 
59
60
61
...
55
56
57
 
58
59
60
61
62
63
64
65
0
@@ -55,7 +55,11 @@ class Dispatcher
0
     # mailers, and so forth. This allows them to be loaded again without having
0
     # to restart the server (WEBrick, FastCGI, etc.).
0
     def reset_application!
0
- ActiveRecord::Base.reset_subclasses if defined?(ActiveRecord)
0
+ if defined?(ActiveRecord)
0
+ ActiveRecord::Base.reset_subclasses
0
+ ActiveRecord::Base.clear_active_connections!
0
+ end
0
+
0
       Dependencies.clear
0
       ActiveSupport::Deprecation.silence do # TODO: Remove after 1.2
0
         Class.remove_class(*Reloadable.reloadable_classes)

Comments

    No one has commented yet.