# Routing issues in controller module

**URL:** <https://www.ruby-forum.com/t/routing-issues-in-controller-module/112241>\
**Category:** Rails\
**Created:** [August 16, 2007, 6:27pm UTC](https://www.ruby-forum.com/t/routing-issues-in-controller-module/112241 "2007-08-16T18:27:39Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![dotjake](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/c67d28/32.png) [@dotjake](https://www.ruby-forum.com/u/dotjake)\
**Post date:** [August 16, 2007, 6:27pm UTC](https://www.ruby-forum.com/t/routing-issues-in-controller-module/112241/1 "2007-08-16T18:27:39Z")

</div>

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](http://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.

---

<div class="post-metadata">

**Author:** ![dotjake](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/c67d28/32.png) [@dotjake](https://www.ruby-forum.com/u/dotjake)\
**Post date:** [August 17, 2007, 1:27am UTC](https://www.ruby-forum.com/t/routing-issues-in-controller-module/112241/2 "2007-08-17T01:27:35Z")

</div>

dotjake wrote:

> 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.

–  
Michael W.

---

<div class="post-metadata">

**Author:** ![dotjake](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/c67d28/32.png) [@dotjake](https://www.ruby-forum.com/u/dotjake)\
**Post date:** [August 17, 2007, 7:26pm UTC](https://www.ruby-forum.com/t/routing-issues-in-controller-module/112241/3 "2007-08-17T19:26:20Z")

</div>

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