routing issues in controller module

I'm having problems with the routing of requests on my production server, running mongrel_cluster with apache. The problem does not happen on my local mongrel test server. Here's an example of what's happening:

I have two controllers, AccountController and Admin::AccountController, each with a separate login action. When I navigate to mysite.com/admin/account/login, sometimes it returns the correct login page, stored in app/views/admin/account/login.rhtml, and sometimes it shows the view from the other AccountController, located in app/views/account/login.rhtml. It does not switch with any apparent regular pattern, almost as though it's confused which one I'm requesting.

Any help would be greatly appreciated.

dotjake wrote:

I'm having problems with the routing of requests on my production server, running mongrel_cluster with apache. The problem does not happen on my local mongrel test server. Here's an example of what's happening:

I have two controllers, AccountController and Admin::AccountController, each with a separate login action. When I navigate to mysite.com/admin/account/login, sometimes it returns the correct login page, stored in app/views/admin/account/login.rhtml, and sometimes it shows the view from the other AccountController, located in app/views/account/login.rhtml. It does not switch with any apparent regular pattern, almost as though it's confused which one I'm requesting.

Any help would be greatly appreciated.

Guessing at the problem I would say that your backend Mongrel processes are actually serving up two different versions of the application. E.g. you changed the app while it was running but didn't shut down all the Mongrel processes before bringing the app back up so some are still serving up the old app. Or you made a change without bringing any of them down but one processes died which was brought back up somehow and so it's serving the new version.

Thanks! I think that was the problem - capistrano was not properly restarting the mongrel processes during the deploy task.