Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Ask HN: The current state of DotNet Web development
8 points by DamonOehlman on Dec 14, 2010 | hide | past | favorite | 16 comments
Hey Guys,

I've been out of DotNet development for a few years (was pretty experienced with 2.0). What are people's current favourite frameworks / approaches for DN development these days. Definitely keen to hear about what people are doing in the land of alt.net as things were starting to get pretty useful even back in the 2.0 days.

BTW, I'm not looking for 'best practice' as I actually don't think such a thing exists, and when people say things like 'best practice approach' I break out in a nasty rash ;)

Nice to have features would be RESTful support and having simple lightweight JSON serialization would be a plus. If the best option is just vanilla DN MVC then I'll go and check it out, but I was interested to hear about alternative options before I start deeper investigation...

Thanks in advance for any suggestions :)

Cheers, Damon.




.NET 4 is fantastic, and highly productive. There are plenty of cool things you can do with the Entity Framework, and WCF Data Services, to get your data tier built quickly, and give you 100% queryable web services that support both OData and JSON without mush hassle.

On the MVC side, ASP.NET MVC 3 is due out any day now, and they have a new rails-like Razor syntax that can really cut down on the coding, if you're into that sort of thing. These days, I do most of my work in Silverlight, because I like rich applications.

If you want to learn how to do these things, Channel9 on MSDN is a HUGE help, with plenty of videos and training on a variety of topics.

I personally think that now is the best time to be a .NET developer... .NET 4 really makes things easy without a whole lot of effort. If you get the option to start from scratch and not have to take a lot of legacy, BS decisions with you, you'll go far quickly.

HTH!

Robert McLaws http://www.windows-now.com


ASP.NET MVC3 is chugging along nicely - I've been using it my new projects and the Razor syntax they introduced has been a huge productivity booster for me. It makes it easier to transition from markup in the view to code (imagine doing (<div>@Model.Property</div> instead of <div><%: Model.Property %></div>) and it makes it easier to read.


Looks like MVC3 is definitely on the table then too...


For the RESTful stuff, there's a big push by the WCF team (now with Glenn Block of MEF fame) to build an HTTP framework: http://wcf.codeplex.com/wikipage?title=WCF%20HTTP There's also a half dozen Sinatra clones. MVC is still a strong option and MVC3 is about to be released. Another popular OSS server framework is OpenRasta. For REST clients, check out Hammock (hammock.codeplex.com) and RestSharp.org (which is my project).

JSON is still a mess in .NET. System.Json should be the answer, but it's not everywhere (it's in Silverlight but not the desktop or phone frameworks). JSON.NET is still the best option. There are some other up and coming JSON libs as well.

Any other questions or areas of concern?


You can just compile Mono's System.Json if you want it on the desktop. a lot of people using the Newtonsoft.Json stuff too.


I know I could (and I've stolen HttpUtility from mono so I could have it in one place everywhere) but it's a hassle.


Thanks for the response - I'll check out some of the suggestions and possibly post back with further questions.


I've used ASP.NET MVC since 1.0 ( ~2 years ago ) for a few projects. It's a pretty nice framework. It's still evolving, so it's not quite RoR/Django yet, but it's really close. I wouldn't go near WebForms anymore, though you can integrate the two.

Aside from ASP.NET MVC, there's a few other frameworks out there. You can check out the web parts of Spring.Net ( http://www.springframework.net/docs/1.3.0/reference/html/spr... ) or MonoRail from Castle ( http://www.castleproject.org/castle/projects.html )


For those tracking the thread, current short list:

Server Frameworks

- ASP.NET MVC3 (http://www.asp.net/mvc/mvc3)

- OpenRasta (http://trac.caffeine-it.com/openrasta)

- Kayak (http://kayakhttp.com/)

REST Clients (not needed straight away but will be handy)

- Hammock (http://hammock.codeplex.com/)

- RestSharp (http://restsharp.org/)

Thanks for the comments so far, it's going to make things a lot simpler.

Cheers, Damon.


I've been very happy with ASP.NET MVC 3's support for the new Razor view engine. I took the leap early and built a couple production apps on that platform. All has been well, thus far.

Exposing your models as RESTful endpoints that return JSON is still accomplished easily enough easy via controller actions that return JsonResult. You can return any object that JavaScriptSerializer can serialize by simply using `return Json(object);`.


How "pure" is the JSON generated using the out of the box serializer? I guess what I'm asking is there much MS cruft in there or does it look pretty clean?


Completely clean...

Except for DateTime types. Since it uses JavaScriptSerializer under the hood, Json() serializes DateTime values as \/Date(ticks)\/. That, of course, is more the fault of JavaScript lacking a Date literal than Microsoft's serializer. Everyone has to solve that problem some way or another.


Take a look at this for details on various alternative servers that have been springing up lately:

http://mikehadlow.blogspot.com/2010/12/explosion-of-alternat...


Kayak and OpenRasta might suit your needs.


Looks like OpenRasta has a pretty solid community built around it and the general design abstraction looks pretty good.

Kayak also looks pretty nifty, but seems to be in a bit of state of flux at the moment (more so than OpenRasta).

Both added to the shortlist though :)


I guess while I'm at it I'll throw my project into the mix. Its still very much under development though and more focused on Mono and running on OSX/Linux.

http://manosdemono.org (nothing really there right now) https://github.com/jacksonh/manos/blob/master/docs/tutorial/...




Consider applying for YC's Fall 2025 batch! Applications are open till Aug 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: