Now this was confusing at first.
So what's with this new ASP.NET component WEBAPI?
While ago I've got task to create lightweight back end for mobile JSON consumer app.
Ok, let's roll WCF, contracts, binding WCF ABC and that stuff.
But no my colleague came with another acronym:
"No man, we'll use WEBAPI REST services. Where have you been, locked up somewhere ? :) "
And on top of it came another statement:
"Look, we must install ASP.NET MVC 4 so we can plug it in ..."
MVC ? What a ...?
Now wait a minute. There is that giant stuff that communicates with everything in the world (and they are building protocol for aliens :) ) called WCF? Right?
It inherited good ol' SOAP like in stone age.
To my humble knowledge that baby goes along and host virtually on anything that can host .NET.
It has nothing to do with MVC or webforms.
So what's the catch?
Well you'd better listen to this great Scott Hanselman minutes (no, I'm not on his marketing payroll :) ):
http://www.hanselminutes.com/264/this-is-not-your-fathers-wcf-all-about-the-webapi-with-glenn-block
Ok, now google REST and you got the picture.
Now, reason for this post was something else. On introduction videos on http://www.asp.net/web-api
there is very important statement about WEBAPI in MVC "skin".
When you create routing for WEBAPI you DON'T define actions as in classic MVC model.
WEBAPI defines standard HTTP REST statements POST, PUT, GET ... as actions.
For me that punches the whole idea on integrating this "baby" wanna be REST WCF into MVC model and it fits just fine give it a try.
No comments:
Post a Comment