ASP.NET MVC 2 RC 2 Released

UPDATE: This blog post is out-of date. We released the RTM of ASP.NET MVC 2 in March 2010. Read about it here.

Today I’m pleased to announce the availability of Release Candidate 2 for ASP.NET MVC 2.

thumbs-upAfter receiving feedback from our last release candidate back in December, we decided it would be prudent to have one more release candidate that incorporated the feedback. You can read the release notes for everything that changed, there’s not a whole lot.

The biggest change in this release was described by Brad Wilson in his blog post on Input Validation vs. Model Validation in ASP.NET MVC. Also included in this release are an assortment of bug fixes and performance improvements.

The window to provide feedback on this release is going to be very short as we are closing in on the RTM. If you want to provide input into this release, please do take the bits for a spin as soon as possible. I’m pretty excited about this release as I can see the end of the tunnel fast approaching. :)

At this point, we’ll only be taking recall class bugs for ASP.NET MVC 2. All other bug reports will be filed against ASP.NET MVC 3. Sometime in the near future, I’ll start sharing some of our planning around that. How exciting!

Oh, and if you missed the link to the Download Details page at the beginning of this post, here it is again.

We also posted the source code and futures assembly on our Codeplex Site.

What others have said

Requesting Gravatar... Asad Ali Butt Feb 04, 2010 1:37 PM
# re: ASP.NET MVC 2 RC 2 Released
great jobs folks, which one of you is going to write about in detail for what is new in the release. Hoping soon, you guys are MSDN alternative when it comes to ASP.NET.
Requesting Gravatar... Martin Aatmaa Feb 04, 2010 2:46 PM
# re: ASP.NET MVC 2 RC 2 Released
Hi Phil,

From the release notes:

"Note Because Visual Studio 2008 and Visual Studio 2010 RC share a component of ASP.NET MVC 2, installing the ASP.NET MVC 2 RC 2 release on a computer where Visual Studio 2010 RC is also installed is not supported."

A similar type of restriction existed in the RC1 release and VS 2010 Beta2.

Assuming I want to run VS 2010 RC with ASP.NET MVC2 RC2, and am OK with giving up the VS MVC tooling support, what process would I need to follow in order to make this work?
Requesting Gravatar... rafek Feb 04, 2010 2:49 PM
# re: ASP.NET MVC 2 RC 2 Released
First of all I'd like to say that you're doin' a great job! I was wondering if Microsoft will ever release any certifications in ASP.NET MVC. (Ya, I know that certifications suck)
Requesting Gravatar... dotnetpower Feb 04, 2010 3:32 PM
# re: ASP.NET MVC 2 RC 2 Released
Great!

Especially, The Model Validation is very useful for me. :)
Thank you.
Requesting Gravatar... O Feb 04, 2010 3:36 PM
# re: ASP.NET MVC 2 RC 2 Released
Any chance you can ETA on the VS 2010 RC so I can finally use ASP.NET MVC RC with it? Also, will the RC of VS2010 work with ASP.NET MVC 2 RC 2?
Requesting Gravatar... Richard Kimber Feb 04, 2010 4:50 PM
# re: ASP.NET MVC 2 RC 2 Released
It's gutting having all this great stuff released and not being able to use it, because you are already using Beta software.
Requesting Gravatar... RichB Feb 04, 2010 4:51 PM
# re: ASP.NET MVC 2 RC 2 Released
Define "recall class bug"?

It seems that this is a Microsoft term for a ShowStopper:
blogs.msdn.com/.../397321.aspx
Requesting Gravatar... Iain Galloway Feb 04, 2010 5:56 PM
# re: ASP.NET MVC 2 RC 2 Released
Thanks for all your hard work!
Requesting Gravatar... Andi G Feb 04, 2010 6:05 PM
# re: ASP.NET MVC 2 RC 2 Released
Fantastic, good to see things moving quickly. Good work

Andi
Requesting Gravatar... Michael Feb 04, 2010 6:32 PM
# re: ASP.NET MVC 2 RC 2 Released
gr8 work,
i'm working on something at the moment that needs to serialize the results of an mvc request, would there be any overhead problems associated with making ActionResult, ViewResult serializable?
Requesting Gravatar... Eduardo Mendes those Feb 04, 2010 7:43 PM
# re: ASP.NET MVC 2 RC 2 Released
great!

I'll do some tests ^^
Requesting Gravatar... Mark Perry Feb 04, 2010 8:42 PM
# re: ASP.NET MVC 2 RC 2 Released
You may want to look at the CreateAreaManifestTask and the WebFormsViewEngine to use the same paths.

Just had some fun with that this morning.
Requesting Gravatar... Fisher Feb 04, 2010 9:27 PM
# re: ASP.NET MVC 2 RC 2 Released
Will jquery 1.4.1 and its new vsdoc be released with MVC 2 RTM?
Requesting Gravatar... Craig Stuntz Feb 04, 2010 9:52 PM
# re: ASP.NET MVC 2 RC 2 Released
Great work; thanks!

Fisher, John Resig said (on Hacker News) that 1.4.1 was going into the VS release. So I guess the answer is yes.
Requesting Gravatar... Alan Huffman Feb 04, 2010 10:03 PM
# re: ASP.NET MVC 2 RC 2 Released
Fantastic news and great job. Definitely moving in the right direction!
Requesting Gravatar... Richard Feb 04, 2010 10:48 PM
# re: ASP.NET MVC 2 RC 2 Released
Good news - can't wait to get hands on...!
Requesting Gravatar... Brian Chance Feb 05, 2010 12:40 AM
# re: ASP.NET MVC 2 RC 2 Released
Not sure where we are supposed to leave feedback, I posted an issue on the forums a few days ago regarding ModelBinding and ConvertEmptyStringToNull being true by default which changes the current 1.0 behavior without any mention. It would be great to be able to override it (see comments on forum).

http://forums.asp.net/p/1522119/3663022.aspx
Requesting Gravatar... Piers Lawson Feb 05, 2010 1:53 AM
# re: ASP.NET MVC 2 RC 2 Released
Fantastic news about the Model validator.... this was my main gripe when trying to create a wizard in MVC:

shouldersofgiants.co.uk/...

Great to see there may be a solution now.
Requesting Gravatar... ashraf Feb 05, 2010 2:20 AM
# re: ASP.NET MVC 2 RC 2 Released
If I use DataAnnotations validation for MVC then what validation method should I use in service layer or business layer (I use buddy class for DataAnnotations)? any examples?


@Fisher
Will jquery 1.4.1 and its new vsdoc be released with MVC 2 RTM?
YES accourding to Scott Gu.



Requesting Gravatar... guest Feb 05, 2010 3:10 AM
# re: ASP.NET MVC 2 RC 2 Released
What about
aspnet.codeplex.com/.../View.aspx?WorkItemId=5137
?
Requesting Gravatar... haacked Feb 05, 2010 11:55 AM
# re: ASP.NET MVC 2 RC 2 Released
@Martin, yes (AT YOUR OWN RISK) you can uninstall just the ASP.NET MVC 2 runtime (not the tools) and then install ASP.NET MVC 2 RC 2 and it should work.

When VS 2010 RC comes out, it will include ASP.NET MVC 2 RC. You can follow the same steps above (remove MVC 2 RC runtime, then run RC2). In that case, the differences between ASP.NET MVC 2 RC and RC 2 are so minimal, tooling should be unaffected.
Requesting Gravatar... haacked Feb 05, 2010 12:03 PM
# re: ASP.NET MVC 2 RC 2 Released
@RichB "Recall Class" also known as "Show Stopper" or "Ship Stopper" is really a judgement call. Typical criteria include (but not limited to)

1. Major Security Issue
2. Major Adoption Blocker
3. No Workaround

@Fisher yes, jQuery 1.4.1 will be included.
Requesting Gravatar... Martin Feb 05, 2010 12:19 PM
# re: ASP.NET MVC 2 RC 2 Released
Great work! Our team need more control over validation especially in the client side without including any extra library.Is any CustomValidator already included in this version
Requesting Gravatar... Arnis L. Feb 06, 2010 2:21 AM
# re: ASP.NET MVC 2 RC 2 Released
Just wanted to say thanks. Amazing work.
Requesting Gravatar... Fisher Feb 06, 2010 6:35 AM
# re: ASP.NET MVC 2 RC 2 Released
Thanks for answers!
Just got vsdoc for 1.4.1 from vs2008 new mvc project.
One problem. It seems it doesn't work in my VS2010. before 1.4.1. vsdoc for 1.3.2 works fine. I just updated them. and intellisense only shows function parameter without any description.

I also tried in a new mvc project on vs2008. and got error below:

Warning 1 Error updating JScript IntelliSense: D:\Documents\Visual Studio 2008\Projects\MvcApplication3\MvcApplication3\Scripts\jquery-1.4.1-vsdoc.js: Object doesn't support this property or method @ 1108:1 D:\Documents\Visual Studio 2008\Projects\MvcApplication3\MvcApplication3\Scripts\JScript2.js 1 1 MvcApplication3
Requesting Gravatar... Bill F Feb 06, 2010 9:44 AM
# re: ASP.NET MVC 2 RC 2 Released
I 2nd Fisher's bug... I updated to the new vsdoc and 1.4.1 and get the @1108:1 warning, but it might as well be an error because you lose js intellisense because of it. Any updates to fix this yet?
Requesting Gravatar... 0GiS0 Feb 06, 2010 11:38 PM
# re: ASP.NET MVC 2 RC 2 Released
Nice work!

Requesting Gravatar... Matt Tester Feb 07, 2010 11:04 AM
# re: ASP.NET MVC 2 RC 2 Released
Great job. Especially pleased the FormCollection behaviour in RC1 was updated - this prevented me from upgrading! Moving to MVC2 R2 later this week.

Thanks.
Requesting Gravatar... Martin Aatmaa Feb 07, 2010 5:57 PM
# re: ASP.NET MVC 2 RC 2 Released
@Phil

Excellent. Thank you very much for all you hard work.

Looking forward to your return from paternity leave!
Requesting Gravatar... Imran Rashid Feb 07, 2010 8:48 PM
# re: ASP.NET MVC 2 RC 2 Released
While some people are against model validation and I can understand where they are coming from, but in this instance I think model validation makes perfect sense. As point out by Brad Wilson though, it should not be taken as a security feature as there are still ways to underpost and overpost.

Keep up the good work.

Requesting Gravatar... Nick Feb 10, 2010 6:17 AM
# re: ASP.NET MVC 2 RC 2 Released
I made the mistake of uninstalling the MVC Tools support for VS2010, and now I can't seem to determine where it came from in the first place. Where can I get the tooling support for VS2010 again? I'm using VS2010 RC and MVC 2 RC2.

Requesting Gravatar... haacked Feb 10, 2010 2:59 PM
# re: ASP.NET MVC 2 RC 2 Released
@Nick, try repairing the VS 2010 install.
Requesting Gravatar... Dan A Feb 10, 2010 10:15 PM
# re: ASP.NET MVC 2 RC 2 Released
Phil,

I just swapped out RC1 for RC2 in my application and now the model binding to a collection does not work. Can someone look into this?
Requesting Gravatar... Kevin Feb 11, 2010 9:29 AM
# re: ASP.NET MVC 2 RC 2 Released
Phil, why does Microsoft insist on releasing Readme and Release Note files in doc format? Not all of us have, nor want, Word on our systems. Why not a docx format. At least we can read docx files in Wordpad.
Requesting Gravatar... santhosh Feb 16, 2010 6:27 PM
# re: ASP.NET MVC 2 RC 2 Released

I have seen in RC 2 release notes says

"The new UrlParameter type allows default values in routes to be removed after URL routing runs."

But I still get the route values in the path.

Here what i get:

<% using (Ajax.BeginForm("Partial", new { id = "test" }, new AjaxOptions() { UpdateTargetId = "PartialView" }))
{ %>
<button type="submit">
Submit</button>
<%} %>

Output of the Ajax URL is:

/Home/Partial/test

Where the Route Values also included in the Ajax Path.

Is this default behavior or defect...?

Thanks,
Santhosh
Requesting Gravatar... santhosh Feb 16, 2010 7:54 PM
# re: ASP.NET MVC 2 RC 2 Released
I have seen in RC 2 release notes says

"The new UrlParameter type allows default values in routes to be removed after URL routing runs."

But I still get the route values in the path.

Here what i get:

<div id="PartialView">
<%Html.RenderAction("Partial"); %>
</div>
<% using (Ajax.BeginForm("Partial", new { name = "test" }, new AjaxOptions() { UpdateTargetId = "PartialView" }))
{ %>
<button type="submit">
Submit</button>
<%} %>

In Partial Page:

<% using (Ajax.BeginForm("Partial", new AjaxOptions() { UpdateTargetId = "PartialView" }))
{ %>
<%=Html.TextBox("test") %>
<%} %>

Output of the Partial View Ajax URL is:

/Home/Partial?name=test

Where the Route Values also included in the Ajax Path.

Is this default behavior or defect...?

Thanks, Santhosh
Requesting Gravatar... Lee Smith Feb 23, 2010 11:43 PM
# re: ASP.NET MVC 2 RC 2 Released
Re: JQuery intellisense

Only this combination gets intellisense working for me:

<script src="../../Scripts/jquery-1.4.1.js" type="text/javascript"></script>

<script src="../../Scripts/jquery-1.3.2-vsdoc2.js" type="text/javascript"></script>
Requesting Gravatar... Mike H Feb 28, 2010 10:22 AM
# re: ASP.NET MVC 2 RC 2 Released
Can you confirm if MVC 2 will go PL so it is allowed to be run under mono?
Requesting Gravatar... Tim S Mar 02, 2010 8:15 AM
# re: ASP.NET MVC 2 RC 2 Released
Is ASP.NET MVC going to get a release built for C# 4.

Currently having a bit of a dependency nightmare building an extension for MVC that needs to support both MVC2 and Entity Framework 4.
Requesting Gravatar... Ben Mar 09, 2010 7:41 PM
# re: ASP.NET MVC 2 RC 2 Released
A little late out the gate on my side, but nice work on the release!

I realise that I can get the source, but what are the chances of including the pdb's with releases? It would make debugging a lot simpler...
Requesting Gravatar... çiçek Aug 05, 2010 10:02 AM
# re: ASP.NET MVC 2 RC 2 Released
While some people are against model validation and I can understand where they are coming from, but in this instance I think model validation makes perfect sense.

Thanks admin...
Requesting Gravatar... çiçek sepeti Aug 18, 2010 7:33 AM
# re: ASP.NET MVC 2 RC 2 Released
Currently having a bit of a dependency nightmare building an extension for MVC that needs to support both MVC2 and Entity Framework 4.

Thanks admin.

What do you have to say?

(will show your gravatar)
Please add 5 and 1 and type the answer here: