~/talk

What's New in ASP.NET Core?

Talkat .NET Conf 2018 · 2018-09-12..09-14· [web-platform, dotnet]
slides:none on file

ASP.NET Core 2.2 preview adds concrete tools and behaviors: Kestrel gains HTTP/2 support (no server push yet), IIS gets a new in-process IIS hosting model that claims ~4x throughput in a JSON benchmark, and a built-in health checks endpoint ties to Azure Traffic Manager. Developer workflow shows the .NET global tool HTTP REPL for interactive API calls, Swashbuckle + an API analyzer and conventions to fix Swagger docs, and MSBuild/NSwag codegen for client libraries — all demonstrated end-to-end.

AI-written summary · about

  1. 0:00Start
  2. 1:20They all Work Great Side by Side so You Can Install Them without Fear that They Will Have any Impact on Your Development Workflow So Let Me Show You Quickly How To Go and Do that So Let's Just Hop Over to a Browser Real Fast To Get the 2 2 Sdk You'Re Going To Want To Go to Dotnet and Then Go to the Downloads Page That's the Downloads Tab Tab up Top and You Should See this Nice Banner at the Top of the Page That Says if You Want To Try Out 2 2 Make Sure You Download the Preview
  3. 1:37And Then Go to the Downloads Page That's the Downloads Tab Tab up Top and You Should See this Nice Banner at the Top of the Page That Says if You Want To Try Out 2 2 Make Sure You Download the Preview 2 Installer if You Click on that Link That Will Bring You to this Page and You'Re GonNa Want To Install the Sdk for Your Platform and Architecture of Choice and Then after You'Ve Done that if You Also Want To Deploy to that 2 Applications to an Ias Based Environment You'Re Probably Also Going To Want To Go Over Here and Install the Runtime and Hosting Bundle once You'Ve Installed the Sdk You Should Be Able To Verify that Things Are All Set Up and Working by Going to the Command Prompt
  4. 2:06Once You'Ve Installed the Sdk You Should Be Able To Verify that Things Are All Set Up and Working by Going to the Command Prompt and Typing Net-- Version You Should See a 2 2 Version of the Sdk for Preview-. if Actually if I Run Net --Info You Can See that I'Ve Got Lots of Sdks Installed So like I Said these Things Are all Side by Side and They Work Great Together the Uninstall Cleanly Now if You'Re Using Visual Studio You'Re Going To Want To Go to Visual Studio Comm Slash Preview and Install the Preview Channel of Visual Studio To Use these Bits
  5. 5:53So that You Can Make Sure that Your Api Is and Apps Are Live and Ready for for Traffic We'Ve Revised Routing Significantly in this Release into a New Routing System That We Call Endpoint Routing Which Has Much Better Performance and Also Takes a Lot of the Concerns That Are Today Handled in Mvc and Makes Them Available Much Lower in the Stack So for Example if You Want To Generate a Link from a Middleware
  6. 8:40It's Not the Best Tool for Doing Api Testing and Debugging I Mean It Really Can Only Do Get Requests by Default unless You Want To Write some Code Maybe We Can Can Do Better So What We'Re Doing In in 2 2 Is We'Re Introducing a New Tool That We Call the Http Repple and It's a Dotnet Core Global Tool That You Can Install a Machine That Gives You a Command Line Interactive Repple for Interacting with Api Endpoints All Right So How Do I Get this this Tool so You Install It from the Command Line It's a Dotnet Core Global Tool
  7. 10:08So You Can Then Execute It I'Ve Already Installed It and I Can Verify that by Doing a Dot Net Tool List-G To See All the Global Tools That I Have in the Machine and You Can See Our 40 Got the Hp Repple Installed All Right Cool So Now I Should Be Able To Do Dotnet Http Ruppel and that Will Then Pop Me into this Interactive Repple for Interacting with Api Endpoints Now Right Now It Says It's Disconnected It's Not Connected to Anything so What Do We Do so We Can Use this Rebel To Talk to either Asp Net Core Api's or Really any Api That You Want So for Example I Could Point It at the Github
  8. 10:29So What Do We Do so We Can Use this Rebel To Talk to either Asp Net Core Api's or Really any Api That You Want So for Example I Could Point It at the Github Api So Let's Point It at Api Github Com Alright Cool So Now It Says It's Connected and if I Run the Help Text Just To See What this Thing Can Do You Can See that from the Repple I Can Issue any Http Requests for any Http Method I Can Set Headers I Can Whoa Look It Looks like It Has Information It Knows How To Deal with Swagger Documents so if You Have an Api That Has a Open Api Spec or a Swagger Document the Two Can Light Up Additional Functionality
  9. 12:14I Can Point this to My to My Web Api for a Spirit Core Let's Try that So I'M Just GonNa Grab the Base Url for My a Speed on a Core Api So Set Base once at the Base to There Good and I Should Be Able to a Get Request and You Know Well Currently at the Root We Don't Have Anything That's due to Api Slash Was It Values Is There Api Yeah Okay So I Can Use the Repple to a Test Api
  10. 14:25And Now I'Ve Got a Much More Feature-Rich Api It's Got Actions for Getting All My Pads Getting Individual Pads and Then Put Post and Delete and these Are Action Methods That Actually Have You Know Code in Them like It's Using a Database Context To Save Data and Manipulate Data so that Looks Good All Right Now One More Thing I Want To Switch the Launch Url for this Application To No Longer Be Api Slash Values in Fact Let's Just Put It at the Root
  11. 14:49And I Want To Use My Hp Repple To Now Test this this Api How Can I Do that So I'M GonNa Wire It Up in Visual Studio and the Way I'M Going To Do that Is by Going To Browse Width in the Drop Down by the Little Run Button and that Will Allow Me To Select Which Browser I'D Like To Use for Testing My Api So Instead of Using the like a Normal Browser like Edge I'M Going To Use the Hb Repple So How Did I Do that I Just Clicked Add and Then You Specify the Path of the Hb Repla Executable You Can See that Down below It's in Your User Profile under the Dotnet Tools Folder and since that I Set that Up So Let's Browse to Our Api Using the Hp Ripple Alright Cool So Now I Should Be Able To Do I Get To Like Api Slash Pets and Oh this Is Probably Going To Crash because I Haven't Done Anything with Migrations
  12. 16:14And Then Run that Code To Generate a Whole Bunch of Sequel for Setting Up the Tables for My for My Pets Api We'Ll Just Give It a Second and There Goes a Whole Bunch of Sequel Ok So Now It Should Be All Set Up and I Should Be Able To Reissue that Get Request One of the Things I Really Like about the Repla You Just Arrow Up and Re-Execute and Ok Now We'Ve Got a an Empty Array of Pets We Don't Have any Pets Yet Okay So How Do I Add some Pets Well I Could Do It Also from the Repple Right Now but the Repple Can Become Much More Feature-Rich
  13. 17:02So What I'M GonNa Do Now Is Go Ahead and Enable Swagger Generation for My Pets Api So Let's Go Back to the Project and I'M Going To Use a Community Project Called Swashbuckle To Enable Swagger Documentation So Let's Manage Nougat Packages and I'M GonNa Add Swashbuckle Asp Core and that's Browse for It So on You Get To Work There It Is and Let's Go Ahead and Install that if You Haven't Used Swashbuckle before It's a Great Open Source Project That Does Swagger Generation for a Spinet Core Applications this Is the the Github Repo
  14. 20:28So We Have To Do a Little More Work To Add some Attributes To Make It Aware of those Things and We Can Do that We Can Go Back to the Pets Controller and We Could Go to the You Know the and on the Post Action and Use the Appropriate Attribute So I Happen To Know that It's Something like I Think It's Produces Response Type but Then You Specify the Status Code and What Type It Returns We Could Do that Manually that Would Be Pretty Tedious and There Would Be no Good Way To Enforce
  15. 29:13And It Pointed It at the Pet Swagger Jason File Specified the Namespace I Specified a Couple of Additional Parameters like I'D Like To Be Able To Inject the Hp Client That It Uses So I'Ve Set that to True and Then I'Ve Also Specified What the Output File Name Should Be Okay So Let's Save that and Now if I Just Build My Api Client Library Hopefully I'Ll Get some Client Code Let's See if that Works Bills Exceeded and Voila We Have a New Pet Client That's Yes File with some Generated Code That I Can Use To Consume the Api Now that Whole Experience of You Know Acquiring the Swagger or a Open Api Spec for an Api Pointing a You Know Your Build for a Library to that Document
  16. 29:55And Having a Generate Client Code for You We Want To Make that Experience a Lot More Seamless in 2 2 So in Preview 3 the Next Preview We'Re Actually Going To Be Providing some Msbuild Infrastructure so that You Can Just Add a Package and Then in Msbuild Say I Would Like To Generate a Client for that Project over There Kind Of like a Project Reference or I'D Like To Generate a Client for that Api over There I'M Using a Url and Have that Just Work and We'Re Planned To Be Working with the Existing Community Projects like N Swag
  17. 31:40It's Just an Experimental Project That We'Ve Been Working on Okay so that's Create a New Blazer App I'M GonNa Add It to My Solution Very Cool All Right and Now that's Just a Reference from My Blazer App to the Client Library That I Just Created Previously Generated from Swagger All Right Now I Need To Also There's One Workaround I'M GonNa Have To Do with the Blazer App Currently this Is Something That We Will Be Fixing in the Future in Order To Allow It To Work with Mints Often It's Just a Temporary Limitation but I'M GonNa Turn Off the Blazer Linker this Will Make the App a Little Bit Larger but It Will Make More Things Work
  18. 37:47Scaffolders
  19. 38:33Monitoring
  20. 39:48Impact of Http Hb 2
  21. 42:19In Proc Hosting Model for Iis
  22. 45:15Health Checks
  23. 48:26Performance Routing
  24. 50:25Endpoint Routings
  25. 51:25Parameter Transformers
  26. 52:03Java Client
  27. 52:39Android Studio
  28. 53:37Android Emulator
  29. 55:20Any Plans To Provide an Updated Templates for View Gis
  30. 58:28Are There any Options for Managing Secrets like Connection Strings with Passwords Etc Other than in Key Vault
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.