I have an odd error. When I first deploy my Azure app I can view the mobile version of the site (Index.Mobile.cshtml). 15 minutes later I get the desktop view instead (Index.cshtml).
If I browse the website once every 10 minutes then I see the mobile version for as long as I want (tested 6 clicks over an hour). I then didn’t click a link for 15 minutes, when I did I got the desktop version again.
If I restart IIS then the process repeats, I first get the mobile version, keep refreshing for 5 minutes and I correctly see the mobile version. Wait 15 minutes and I get the desktop version.
The same code running on a physical server stays correct and debugging locally works too.
The _ViewSwitcher correctly still says I’m on the mobile version but it’s not using the Index.Mobile.cshtml version of the page.
I’m running ASP.NET MVC 4 RC.
Has anyone experienced this issue before?
This is a known bug to do with MVC4:
http://aspnetwebstack.codeplex.com/workitem/280?PendingVoteId=280