Hi, I am using rails 2.3.2, apache 2.2, active scaffold, and mongel. I was caught by surprise when an application that was working started to fail. Digging into things showed that the error occurred when cache_classes = true (even though it worked this way before, setting cache_class to false now fixed the problem). Naturally, this is not an actual fix for a production application, as it has slowed way down. I have seen in other posts that people had problems with running rake in production with active scaffold, but have not seen others with this problem, where the web server fails to start. Does anyone know any more information about cache_classes? Since it seems to work then the code keeps getting reloaded, is it possible that I need to manually clear this cache somewhere? Could this problem be related to Active Scaffold? Thank you for any information! Steve
Frederick Cheung
2009-Aug-26 16:13 UTC
Re: cache_classes = true causes application to fail
On 26 Aug 2009, at 16:26, Steve wrote:> > Hi, > > I am using rails 2.3.2, apache 2.2, active scaffold, and mongel. I > was caught by surprise when an application that was working started to > fail. Digging into things showed that the error occurred when > cache_classes = true (even though it worked this way before, setting > cache_class to false now fixed the problem). Naturally, this is not > an actual fix for a production application, as it has slowed way > down. I have seen in other posts that people had problems with > running rake in production with active scaffold, but have not seen > others with this problem, where the web server fails to start. Does > anyone know any more information about cache_classes? Since it seems > to work then the code keeps getting reloaded, is it possible that I > need to manually clear this cache somewhere? Could this problem be > related to Active Scaffold? Thank you for any information! >cache_class=true means (among other things) that code gets loaded up front when the application starts. One way this can go wrong is at the bottom of http://www.spacevatican.org/2008/11/21/environment-rb-and-requiring-dependencies Fred> Steve > > --~--~---------~--~----~------------~-------~--~----~ > You received this message because you are subscribed to the Google > Groups "Ruby on Rails: Talk" group. > To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org > To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org > For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en > -~----------~----~----~----~------~----~------~--~--- >