urine for a treat (or: asp.net mvc)

Post on 12-Jan-2015

3.091 Views

Category:

Technology

2 Downloads

Preview:

Click to see full reader

DESCRIPTION

The "ASP.NET MVC" presentation done by Barry Gervin and Joey deVilla for Stack Overflow DevDays Toronto on Friday, October 23rd, 2009.

TRANSCRIPT

Urine for a Treat(or: ASP.NET MVC)

Barry Gervin, ObjectSharpand

Joey deVilla, Microsoft

First came ASP…

…then cameASP.NET…

…and now,ASP.NET MVC

Model-View-Controller

ASP.NET MVC’s MVCControllerHandles input(HTTP requests)

ViewVisually representsthe model

Request

View

Controller

Response

ModelDoes the thinkin’and persistence

Routing

mysite.com/object/action/parameter

ConventionOver

Configuration

Testability

Master of Your Domain

ASP.NETtyGoodness

Baked Right In

ASP.NET Runtime

ASP.NET MVC

Microsoft.com/web

Web Platform Installer

RunPee.com (Yes, it’s a real site!)

MovieWhizz

“Classic” ASP.NET vs.ASP.NET MVC

ComparingRuby on Rails

andASP.NET MVC

David Heinemeier Hansson

The “Gang of Foreheads”

Programming Language

ASP.NET• C# or Visual Basic• Compiled• Statically typed• Java-esque syntax• Strongly tied to

Visual Studio IDE

Ruby on Rails• Ruby• Interpreted• Dynamically typed• Smalltalk-y, Perl-y,

Lisp-y syntax• Culturally tied to

TextMate

Design Philosophy

ASP.NET• There really should

be a form of ASP.NET that actually treats the Web like the Web

• “Whatever, man.”• Built as a general

purpose framework for web developers using ASP.NET as a base

Ruby on Rails• There really should be

a Web programming framework that maximizes joy

• “There’s a right way to do things, and it’s this way.”

• Extracted from commonalities in 37Signals projects

Database

ASP.NET• “SQL! Whoooo!”• More exposure to the

database• Typically, you build a

Repository class to act as a go-between for your models and the database

• Traditional database building

Ruby on Rails• “SQL! Ewwww!”• DHH’s opinion is that

the database is just storage

• Database persistence is provided by the model

• Database building through migrations

Out soon: ASP.NET MVC 2

• A good number of new features including:– Client-side validation based on the

model’s validation metadata– Areas to better organize an application–Model validation providers to hook in

alternative validation logic when model binding

–Metadata providers to allow for alternative sources of metadata for model objects

ASP.NET MVC as Seen by a Former Rails Guy, Techincally

• Really fast runtime performance!• Could stand to be a little more

“opinionated”• Coming from the world of ActiveRecord, the

“M” in MVC feels like it should be short for “Missing”

• More lines of code, but Visual Studio’s Intellisense help compensate for that

• Where are my plugins?• Could go either way on the lack of RJS

ASP.NET MVC as Seen by a Former Rails Guy, Culturally

• Yes, this isn’t the first MVC framework, but the world is a better place when people take a good idea and run with it

• Moving from Rails to ASP.NET MVC, I kind of miss that Indie Rock feeling, but I like the Arena Rock opportunities

• “I’m not selling out, I’m buying in!”

Resources

NerdDinner (nerddinner.com)

Professional ASP.NET MVC 1.0,a.k.a. The “Gang of Foreheads” Book

ASP.NET MVC in Action(Follow @ManningBooks on

Twitter)

Pro ASP.NET MVC Framework(Highest rating on

Amazon.com)

The Official ASP.NET MVC SiteASP.NET/MVC

You’ve Been Haacked (Phil Haack)

Haacked.com

Scott Hanselman’s BlogHanselman.com

ASP.NET MVC aggregator siteASPDotNetMVC.com

This site will pull downthe pants of your mind

ObjectSharpObjectSharp.com

Canadian Developer Connection

blogs.msdn.com/cdndevs

Global NerdyGlobalNerdy.com

Thank You

top related