ef core (rc2)
TRANSCRIPT
![Page 1: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/1.jpg)
Ido Flatow
Entity Framework Core (EF Core) 1.0
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatowJoin the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
![Page 2: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/2.jpg)
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
About MeSenior Architect, Sela GroupMicrosoft Regional Director, and an ASP.NET/IIS MVPCo-author of courses and booksFocus on server, web, and cloud
![Page 3: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/3.jpg)
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
Entity Framework Project Status
New runtime components on NuGetCore runtime components in .NETTooling in Visual Studio
Runtime in .NET FrameworkTooling in Visual Studio
Runtime on NuGetTooling on Microsoft Download CenterLatest version included in Visual Studio
Entity Framework 3.5 SP1
Entity Framework 4
Entity Framework 4.x
Entity Framework 5
Entity Framework 6.x
Entity Framework 6.2 Entity Framework Core 1.0
![Page 4: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/4.jpg)
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
TodayWritten to target relational databasesEF6.x DLL files are over 5MBRuns only on full .NET FrameworkNo support for batch updates
![Page 5: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/5.jpg)
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
EF Core Key FeaturesRewritten from the ground up to be lightweight (under 1MB)New platforms & data storesIoC friendly and extensibleOptimized query generationCode-First onlyBatching
![Page 6: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/6.jpg)
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
.NET FRAMEWORK .NET CORE XAMARINAP
PM
ODEL
SBA
SELI
BRAR
IES
Base Class Library Core Library Mono Class Library
ASP.NET
Windows FormsWPF UWP
ASP.NET Core
iOSAndroid
Compilers Languages Runtime components
COMMON INFRASTRUCTURE
OS X
New Platforms
EF6.x EF Core
![Page 7: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/7.jpg)
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
New Data StoresRelational & non-relational
Not a magic abstractionHigh level services that are useful on all/most storesNon-common concerns handled by provider extensions
Example providersRelational (SQL Server, SQLite, Postgres, SQL Compact etc.)In Memory (for testing)Azure Table StorageRedis cache
Just relational providers for v1.0
![Page 8: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/8.jpg)
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
Lightweight & Extensible CoreSame top level experience as EF6.x
Still DbContext/DbSet etc.New core
Core = metadata, change tracking, query pipeline, etc.Built as a collection of services with dependency injectionEasier to replace/extend servicesReplace confusing APIs & behavior
Optimized for memory and CPU usagePay-per-play components
![Page 9: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/9.jpg)
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
EF6.x – The End?!Will continue to be a supported releaseMicrosoft will continue with bug fixes and small improvements to the code baseFirst preview of EF6.2 will be available shortly after EF Core reaches RTM
![Page 10: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/10.jpg)
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
Some New FeaturesMixed C#/database eval in LINQ queriesBatch saveSQL query improvementsShadow state propertiesAlternate keysTrackGraph API
![Page 11: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/11.jpg)
Demo
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
EF Core Basics
![Page 12: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/12.jpg)
Demo
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
LINQ and SQL Query Improvements
![Page 13: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/13.jpg)
Demo
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
Simplified Metadata API
![Page 14: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/14.jpg)
Demo
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
Extensible Core
![Page 15: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/15.jpg)
Demo
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
New Data Stores
![Page 16: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/16.jpg)
Demo
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
New Features
![Page 17: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/17.jpg)
Demo
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
New Platforms
![Page 18: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/18.jpg)
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
EF Core 1.0 Feature Status (condensed version)Backlog
Lazy loadingComplex value typesStored procedure mappingData seedingUpdate model from databaseMany-to-many relationships without a join entityInheritance mapping with TPT and TPCCommand interception
In ProgressBug fixingPerformance improvementsLINQ improvementsDocumentation and Intellisense
Thrown outEDMXEntity SQLObjectContext API
![Page 19: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/19.jpg)
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
EF Core & EF6.xEF6.x will be the right choice for many applicationsCarefully evaluate requirements if considering EF Core
Some important features not implemented in 1.0 (e.g. lazy loading, stored procedure mapping, etc.)Less mature code base (e.g. LINQ translator has limitations)
EF6.x to EF Core is “port” not “upgrade”Very basic code will port easilyMany APIs have changed drasticallyBeware of behavior differences in similarly named APIs
![Page 20: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/20.jpg)
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
When to Use EF Core?New applications that do not need the features that are not yet implemented in EF Core
Applications that target .NET Core, such as Universal Windows Platform (UWP) and ASP.NET Core applications
![Page 21: EF Core (RC2)](https://reader036.vdocuments.site/reader036/viewer/2022081422/58f2d5b71a28abee768b4579/html5/thumbnails/21.jpg)
Join the conversation on Twitter: #ndcoslo // @NDC_Conferences // @idoFlatow
Next StepsDocumentation
docs.efproject.netgithub.com/aspnet/EntityFramework/wiki/Roadmap
Repositoriesgithub.com/aspnet/EntityFrameworkgithub.com/rowanmiller/Demo-EFCore
Blogsblogs.msdn.microsoft.com/dotnetblogs.msdn.com/b/adonet (older)
My demo codegit.io/voYzr