0

We've been working with .Net v3.5 SP1 and MVC 2. Backend SQL Server 2005. Its a web 2.0 web app using several AJAX & jQuery features.

Now we want to migrate to .Net v4.0 and MVC 3. The main reason being that most of the upgrades and enhancements go better with MVC3. We want to migrate in a way that will ensure the stability and if possible help us migrate fast & safe.

I found a few threads on SO but its been a long time so I wanted know the best approach.

Can we delay the migration to 'Razor view engine' for our views? Apart from that what are the changes we shud be prepared to work out during the migration. For example, here're a few I'm aware -

  • I believe our web.config would have a major make over in .Net v4.0.
  • Would the RegisterRoutes need any changes?
  • Any specific things to look into the Global.asax.cs?
  • We've user controls & editor templates - any changes?
  • We've explicitly referenced user controls as well as Html.EditorFor - any changes or updates?
  • Form based authentication, Attributes, Extension methods, Action Filters, etc... I hope these old things would adapt just fine.

Platform: I hope VS.Net 2010 + MVC 3 would be sufficient or need any SP, etc.. ?

Can any tool(s) help - like: http://blogs.msdn.com/b/marcinon/archive/2011/01/13/mvc-3-project-upgrade-tool.aspx

I've gone thru the famouse scottgu ref link. It does have a lot of info but not much for migration. Sorry for being late. I just wanted to avoid mistakes from your learning.

Thank you.

Ref: Could it be as simple as this! OR http://www.mrrives.com/Technology/?p=743

Hemant Tank
  • 1,724
  • 4
  • 28
  • 56

1 Answers1

0

Here's how I went ahead with my upgrade -

MIGRATION A detailed explanation about the migration process and the changes it'll make. Actually it is as deep(old) as ASP.Net v1.1 for v3.5 things are easier(skip those manual updates provided for ASP.Net v1.1 to 3.5 migration. For example, you won't need to upgrade your user-controls and pages for the partial class design if your app is in v3.5)

http://msdn.microsoft.com/en-us/magazine/ff956194.aspx

Not to mention, make sure you've got a backup and also care to go thru the conversion log for issues. VS.Net 2010 conversion wizard is at your service.Optionally, you can stay with target .Net framework v3.5 or upgrade to v4.0 (as I did)

POST MIGRATION You'll want to look for some .Net v4.0 upgrade related issues - like it'll HTMLEncode the text content of your controls and URLs (so " " will become "%20") - I had a few hiccups!

web.config updates like - controlRenderingCompatibilityVersion, etc ... Here's a good ref -

http://www.hanselman.com/blog/IntegratingASPNETMVC3IntoExistingUpgradedASPNET4WebFormsApplications.aspx

Finally MVC 3 UPGRADE Manually, it'll be hard if not complex so I went ahead for an automated tool. Its been awesome!

http://aspnet.codeplex.com/releases/view/59008

Hope this helps. I'm still testing and revising my web app for any other issues post migration. Let me know if there're any edits!

Thank you.

Community
  • 1
  • 1
Hemant Tank
  • 1,724
  • 4
  • 28
  • 56