
Introducing ASP.NET vNext - ragesh
http://www.hanselman.com/blog/IntroducingASPNETVNext.aspx
======
Goosey
This is extremely exciting. The lack of a 'No-compile developer experience'
has been one of the biggest annoyances for me and my team. It actually has
lead to influencing our coding patterns: since we can "refresh and see new
code" for anything that is in the view templates (Razor *.cshtml in our case)
we have become increasingly in favor of putting code there (or in javascript
frontend 'thick client' code) to take advantage of not needing to recompile.
It's not like recompiling is slow (maybe 5sec in our case), but it still
breaks your flow and more importantly requires stopping the debugger if it is
in use. In some ways the code has improved, in some ways it hasn't, but in
either case it feels like the tail wagging the dog when you are changing how
you structure code based on your tool's inadequacies.

I'm equally excited for the intentional mono support and "Side by side -
deploy the runtime and framework with your application". ASP.NET MVC and Web
API are really pleasant and mature frameworks, but configuring IIS has always
been really unpleasant and clunky.

~~~
edandersen
You are putting increasing amounts of code in your Razor views?

~~~
nickstinemates
Just wait until they discover PHP :)

------
slg
As a .Net developer, I find all of the recent announcements from Microsoft
really exciting. I just wonder if these type of things are enough to sway
people's opinions regarding the platform. There is just so much baggage in the
developer community when you say .Net or Microsoft ( _edit: as one of the
three comments at the time of this posting proves_ ). Are these moves just
going to stave a potential exodus of .Net developers or will it actually lead
to new developers picking up the language?

~~~
spamizbad
> Are these moves just going to stave a potential exodus of .Net developers or
> will it actually lead to new developers picking up the language?

I definitely think these changes will keep existing .NET developers in the
fold. People who haven't embraced the Microsoft ecosystem at this point
probably won't in the future.

Things I'd say hurt outsider adoption:

1) The ecosystem of freely available .NET libraries is minuscule compared to
what you have with Python, Ruby, PHP, Java, and probably even Node. And the
quality of .NET's 3rd-party commercial packages are typically worse than what
you'd expect from _free_ open source libraries in terms of both software
quality and documentation.

2) Going along with #1, things like database/service drivers, web service
APIs, etc, are never as robust or feature-complete as their
Python/Ruby/PHP/Java etc counterparts. And sometimes they're really late to
the party getting just a basic implementation going.

3) Many .NET shops are technologically conservative, for various reasons, and
don't embrace the new technologies. If you're a developer excited about these
technologies, understand that probably 80% of .NET shops will never touch
these changes with a 10-foot pole for the next 5-10 years outside of rinky-
dink projects.

4) The .NET library itself is kinda unwieldy, and only becomes easier to work
with if you invest in expensive tools (Visual Studio). In the OSS world, you
may have to install a few freely-available tools first, but you get the first-
class experience for no cost pretty much right away. In the editor of your
choice.

5) Once you step out of Azure, advanced deployments of Windows server have a
sizable learning curve that rival Linux in terms of difficulty and complexity.
In fact, today its probably harder, ever since Microsoft re-did technet to
make it way more difficult to get comprehensive information on stuff.

~~~
Encosia
> 4) The .NET library itself is kinda unwieldy, and only becomes easier to
> work with if you invest in expensive tools (Visual Studio). In the OSS
> world, you may have to install a few freely-available tools first, but you
> get the first-class experience for no cost pretty much right away. In the
> editor of your choice.

The "Express" versions of Visual Studio have been available since 2005. You
can install plugins/extensions in the Express SKU, but it's a solid option to
get Intellisense and debugging for students, hobbyists, small shops, etc.

~~~
guiomie
I'm pretty sure you can't install " install plugins/extensions " in the expres
editions of VS. Unless, Express SKU is something different ... ?

~~~
Encosia
You're right. I meant to say "can't" there (and apparently it's too late for
me to edit that comment now).

------
Xdes
"ASP.NET vNext (and Rosyln) runs on Mono, on both Mac and Linux today. While
Mono isn't a project from Microsoft, we'll collaborate with the Mono team,
plus Mono will be added to our test matrix. It's our aspiration that it 'just
work.'"

I wonder whether we will be seeing a .NET web server for mac and linux.
Hosting a C# MVC app on linux will be sweet.

~~~
DougWebb
They're already providing a .NET web server. That's the 'self-hosting'
examples Scott shows in the article: when you run the application that way, it
becomes a web server for your app. It's just like a Node.js application. For a
production deployment on Linux I'd probably run the app using Mono on a
localhost port, and run Apache in front of it with a reverse-proxy config
pointing to localhost.

BTW, if you're not a fan of ASP.Net MVC's style of web framework, take a look
at Nancy[1]. It's much more lightweight, and can also run under Mono on Linux.

[1] [http://nancyfx.org/](http://nancyfx.org/)

~~~
alelefant
I'm really looking forward to the self-hosting features. I have a few client
(Windows Forms) applications that would be so much better within the browser.
Opening that door for client-side web applications where network connectivity
is a major issue would be so helpful.

However, there's 150 comments and no mention of the "vNext" name. Someone else
must find the name silly!

~~~
snuxoll
vNext has been used for a while with ASP.NET and visual studio development.
The next release is canonically called vNext (version next) until a formal
name is given prior to release.

------
konstruktor
I can hardly imagine a more effective developer advocate than Scott Hanselman.
He seems to be doing more good for Microsoft's reputation among developers
than anybody else. Of course he out-HNed the official msdn article. For those
not familiar with his name, here is some of his other stuff:
[http://www.hanselman.com/blog/MakingABetterSomewhatPrettierB...](http://www.hanselman.com/blog/MakingABetterSomewhatPrettierButDefinitelyMoreFunctionalWindowsCommandLine.aspx)
[http://www.hanselman.com/blog/ScottHanselmans2014UltimateDev...](http://www.hanselman.com/blog/ScottHanselmans2014UltimateDeveloperAndPowerUsersToolListForWindows.aspx)

------
bananas
I've been through EVERY ASP.net update on every version of .net and every MVC
update from CTP2 onwards, dealt with WWF being canned and rewritten, moved
APIs between old SOAP stuff (asmx), WCF and WebAPI and rewritten swathes of
ASP VBnand C++ COM code, ported EF stuff to later versions and worked around
piles of framework bugs including the MS11-100 fiasco. That and been left
royally in the shit with silverlight.

Not one of the above has actually improved the product we produce and are all
reactionary "we might get left in the shit again" changes.

I'm really tired of it now.

~~~
PallarelCoedr
This reads like a standard list of a cocooned MS developer. With ServiceStack,
NancyFX, NHibernate, Dapper, OrmLite, etc out there could you have just been
making some bad choices?

And anyone who knew web, knew Silverlight didn't have a future from the very
beginning.

~~~
bananas
The only bad choice was the foundation on which to build the product. The
above technologies are pretty much a response to the world being better
elsewhere. Unfortunately the responses are pretty immature, poorly documented
with bad support reputations and virtually no backing.

I've used most of the above. ServiceStack was pretty good but nothing in
comparison to Jasper which has much better documentation, a cleaner
architecture, stable migration notes and better performance. Look:
[https://jersey.java.net/documentation/latest/index.html](https://jersey.java.net/documentation/latest/index.html)

NancyFX I haven't touched.

NHibernate is a buggy behemoth with a learning curve from hell. It doesn't
scale well with project size (we have 2000 tables of which about 500 are NH
mapped "model-first") and it stinks. The SQL generated is terrible, it's
impossible to debug when it goes wrong other than sift through 50Mb of log4net
DEBUG level logs. To add insult to injury, the LINQ provider is so buggy it's
like programming with a hand grenade. I've used hibernate in java and
NHibernate isn't even a tenth of the way to the maturity and reliability.

Dapper - I really like Dapper. I have used it for data transforms before.
However it doesn't play well with low trust as it uses IL emit.

OrmLite - see ServiceStack.

Not bad choices - just choices I either regret or had to make because the
whole ecosystem is amateurish outside of Microsoft and unstable inside of
Microsoft. Sorry.

~~~
pbz
Have you tried LINQ to DB (not LINQ to SQL) the successor to BLToolkit? We've
had good results with it, but we like to keep our queries and datalayer as
simple and thin as possible.

------
kr4
> ... your choice of operating system,

> we'll collaborate with the Mono team, plus Mono will be added to our test
> matrix. It's our aspiration that it "just work

This. is. superb! I love developing on VS with ASP.NET, and I love *nix
tooling (ssh is pure fun), I was secretly hoping for this to happen.

------
troygoode
Finally switching away from the horrible XML-based CSPROJ files to a more sane
JSON format (that hopefully doesn't require you to list every. single. file.
individually) is the feature I'd be most excited about if I was still using
.NET.

I recall CSPROJ files being the primary source of pain for me as I started to
transition out of the Microsoft world and into the open source world, as it
prevents you from using editors like vim & emacs if you're working in a team
environment.

~~~
guiomie
Can you elaborate on why a json format would be better for a csproj ?

I have issues with the .csproj also, but I don't think json would fix
anything, my issue is usually with visual studio and the confguration manager
not applying changes...

~~~
malkia
For me - it'll be reading it.

I have to deal quite often with "Unload Project file" in MSVC IDE, edit by
hand, "Load again" \- because no matter how good the IDE is (and Visual Studio
is a good IDE overall) there are lots of edge cases where it fails (merging
multiple settings per project / per configuration / etc.)

~~~
ghuntley
re: readability

project.json (.csproj/packages.config/nuspec file replacement) has been
unveiled:

[https://github.com/aspnet/DependencyInjection/blob/dev/src/M...](https://github.com/aspnet/DependencyInjection/blob/dev/src/Microsoft.Framework.DependencyInjection/project.json)

re: load/unload process

VSCommands Pro Extension adds the ability to right click on a project to
automate the unload, edit, reload cycle and offers editing inline.

[http://visualstudiogallery.msdn.microsoft.com/c6d1c265-7007-...](http://visualstudiogallery.msdn.microsoft.com/c6d1c265-7007-405c-a68b-5606af238ece)

------
malaporte
Seems pretty interesting. And official MS support for running the whole thing
on Mono, right now, isn't that pretty big?

~~~
edwinnathaniel
I'd say from capability perspective it's huge.

But capability is half of the story. Tooling/ecosystems is the other half (re:
MonoDevelop is still not up to the snuff).

~~~
malaporte
Yes. If only JetBrains could release an IntelliJ-based IDE for C#, that'd be
nice.

~~~
pionar
It really wouldn't be that hard, Roslyn's out there for compilation, and doing
things like Intellisense.

------
daviding
What is a 'cloud-optimized library'? Does it mean 'small' or have I
underestimated it?

~~~
ahmelsayed
I think he is referring to running different versions with different CLRs
side-by-side. It means Platform-as-a-Service friendly. Since in PaaS you
usually don't own the machine, you just run code somewhere. You don't want to
be tied in with is framework X installed on the machines or not. You want to
be able to pull in what ever framework you like, as you would do with node.js
for example

~~~
daviding
That makes sense - thank you.

I sort of remember that the core CLR didn't really rev that much, in that it
spent the longest time on 2.x, with only the data access technologies built on
top changing what seemed like every other week. LINQ was the next nice
additive.

I don't recall exactly why now, but I know that the term 'strong naming' can
still instill terror in me. I guess that all goes away if you can distribute a
statically linked lump per app. The cycle continues..

------
cuong
How realistic is it to use a self-hosted OWIN server running ASP.NET vNext on
Mono? What can we expect in terms of performance? I was always under the
impression it was pretty far away from being a viable option, Microsoft help
or not.

~~~
giulianob
I started a thread on the Mono mailing list a couple months ago about web
hosting performance on Mono ( [http://mono.1490590.n4.nabble.com/FastCGI-
Performance-td4662...](http://mono.1490590.n4.nabble.com/FastCGI-Performance-
td4662454.html) ). It turns out the default implementation for FastCGI is
really slow. Some members of the community have created a few different
implementations. The fastest one currently is a thin wrapper over evhttp which
can handle over 100k requests per second on a simple benchmark. There are
other discussions as well about how to improve performance.

------
robertlf
So glad I'm no longer a .NET developer. Every year it's a new razor blade.

------
TheRealDunkirk
Yet another piece of mature web-development puzzle that Microsoft is trying to
emulate. That's great, and good luck to them, but my recent efforts with
trying to use Entity Framework suggest that this may not be a viable solution
for a long time to come.

I'm typing this to delay the effort of ripping EF out of my project, and do
ADO.NET Linq-to-SQL. (I guess. Maybe it'll just be raw SQL at this point.)
Unless someone here can answer this question? It's worth a shot...
[http://stackoverflow.com/questions/23528335/how-can-i-
implem...](http://stackoverflow.com/questions/23528335/how-can-i-implement-a-
rails-like-has-many-through-in-entity-framework)

I miss Rails.

~~~
df07
Try Dapper for a simple .NET ORM. We created and use it for Stack Overflow.
[https://code.google.com/p/dapper-dot-net/](https://code.google.com/p/dapper-
dot-net/)

Here's the original post describing how we made it:
[http://samsaffron.com/archive/2011/03/30/How+I+learned+to+st...](http://samsaffron.com/archive/2011/03/30/How+I+learned+to+stop+worrying+and+write+my+own+ORM)

~~~
steverb
Another plug for Dapper. I tell people it's an ORM for developers who aren't
afraid of SQL. It doesn't hide the database, or force you to pretend it's not
there. It excels at taking your rows of data and transmogrifying them to
objects.

~~~
daigoba66
> transmogrifying

Also known as "mapping"; the literal purpose of an ORM. :)

Other big tools/frameworks include APIs for query generation, unit of work,
caching, etc., which are not always necessary or desired.

~~~
mmgutz
Data mappers map tables to objects.

ORM's compensate for the impedance mismatch between objects and tables. They
do a lot more than mapping.

------
adrianlmm
I'd really like that the next ASP MVC comes with full Owin support.

~~~
PallarelCoedr
It does, but internal abstractions have been rewritten. Webforms view engine
won't be ported I reckon.

~~~
adrianlmm
In MVC5 the security layer works on OWIN, I'd like to see the rest of the
stack like routing also decoupled from modules and handlers, fingers crossed
for MVC6.

------
slipstream-
Does anyone else spot the irony of an MS guy using Chrome?

~~~
lavamantis
Good catch, but not terribly surprising. Developers don't use IE except when
they have to test for non-standard behavior. IE hopefully will soon go the way
of the dodo - I no longer see any reason for it to exist.

~~~
ragesh
I used to feel the same way, but recently IE has become an absolute necessity
for me. You see, I own a Windows Phone :)

------
chris_wot
When will they be releasing ASP.NET vNext Compact Enterprise MVC Edition?

------
mountaineer
Tomorrow is my last day as a professional .NET developer, nothing here to make
me think twice about saying goodbye.

------
li2
If you are serious about your career path as software engineer stay away from
windows technologies.

~~~
Swinx43
I would most definitely like to also know why? There are many developers that
work using Microsoft technology, everyone organisation does not build their
services or products on open source.

~~~
li2
Look at some job descriptions of some cool companies facebook/google... Do you
see a simple word being related with windows technologies?

~~~
BSousa
I shouldn't feed a troll but, look at job descriptions from banks/insurance
companies/science/education/betting/automative/health based companies. Do you
see a simple word being related to rails?

ps: I know of some that do, most don't, and they pay a LOT more than all the
'cool' companies.

~~~
rbanffy
> ps: I know of some that do, most don't, and they pay a LOT more than all the
> 'cool' companies.

That's fine if you are working for the money. Personally, I prefer the "cool"
companies, even if they pay less. For some people, wearing a tie and spending
40 years working for a big bank or large insurance company and then retiring
is an option and I respect them. It's not for everyone, however.

~~~
recursive
I've worked for many companies as a developer in an MS stack. I've never had a
dress code that required more than a t shirt.

~~~
rbanffy
So, you disagree with the "wearing a tie" part?

~~~
wfjackson
The other day I had a meeting with some folks in a company that uses .NET and
the CEO showed up in a gym shirt, shorts and sports shoes. You're conflating
the technology with the places it's typically used, there are places that use
RoR where everyone wears a tie.

