17
Getting started with ASP.NET 5 Brij Bhushan Mishra @code_wala

Getting Started with ASP.NET 5

Embed Size (px)

Citation preview

Page 1: Getting Started with ASP.NET 5

Getting started with ASP.NET 5Brij Bhushan Mishra

@code_wala

Page 2: Getting Started with ASP.NET 5

About me

• Brij Bhushan Mishra

• Microsoft MVP – ASP.NET/IIS (4 times)

• Blogger/ Author /Speaker

• http://codewala.net

• @code_wala

[email protected]

Page 3: Getting Started with ASP.NET 5

Key things

• Cloud.. Cloud.. Cloud..

• Agile.. Agile.. (Scrum Kanban.. etc)

• Testing.. Testing.. Testing..

• Open Source..

• JavaScript..

Page 4: Getting Started with ASP.NET 5

Current scenario

• Its working on my machine?

• Wish we were able use ASP.NET..

• So much loading time.. Dunno what’s going behind

• Less control on framework libraries module

• Forced to use IIS

• Can we host my application on Mac

• Production pointing to Dev

Page 5: Getting Started with ASP.NET 5

All these problems will be History!!

Page 6: Getting Started with ASP.NET 5

ASP.NET 5 redesigned

FULL .NET CLR (4.6)

200 MB

Core CLR (Cloud Optimized)

11 MB

Cross Platform CLR

Page 7: Getting Started with ASP.NET 5

What you get..

• Full .NET CLR (Provides backward compatibility)

• Core CLR • Has bare minimum components

• Include whatever you need via NUGET

• Can be deployed independently

• Each components can be updated individually

• Cross Platform CLR

Page 8: Getting Started with ASP.NET 5

Features

• Use different versions of .NET side-by-side

• Simplify dependency management

• Cloud Ready

• Host Anywhere

• Dependency Injection Ready

• Improved Request Pipeline

• Configuration Management

Page 9: Getting Started with ASP.NET 5

Coding and debugging with Visual Studio

Change the code

C# Compiler invoked

Load code in memory

Execute the dll

dll loaded in memory from File system

Emits the dll in file system

Page 10: Getting Started with ASP.NET 5

Coding and debugging with Visual Studio

Change the code

Load code in memory

Code is Executed in

memory

Roslyn compiles code in memory

Time reduced from 7-8 second to 1-2 second

Page 11: Getting Started with ASP.NET 5

Demo

Page 12: Getting Started with ASP.NET 5

The world today

Web pages MVC Web API

Razor

HTML Helpers HTML Helpers

Controllers

Actions

Filters

Model Binding

Dependency Resolver

Controllers

Actions

Filters

Model Binding

Dependency Resolver

Page 13: Getting Started with ASP.NET 5

Now..

MVC Web API Web Pages+ +

=ASP.NET MVC 6!!

Page 14: Getting Started with ASP.NET 5

Getting Started with ASP.NET MVC 6

• Add MVC package : Microsoft.ASP.NET MVC6

• In Startup.cs• In ConfigureServices(IServiceCollection services) method

• Services.AddMvc()

• Services.Configure<MvcOptions>(opions => {…})

• In Configure() method• app.UseMvc(routes => => {…})

Page 15: Getting Started with ASP.NET 5

Demo

Page 16: Getting Started with ASP.NET 5

Web forms is not dead – ASP.NET Web forms 4.6

• HTTP 2

• Async model binding

• Roslyn CodeDOM compilers

Page 17: Getting Started with ASP.NET 5

Thank You

http://codewala.net@[email protected]