SlideShare a Scribd company logo
EF For Cross Platform Apps
@svswaminathan
BDotNet UG Meet, Aug 2016
Swaminathan Vetri
• Senior Engineer @ Target
• Microsoft MVP - Visual Studio &
Development technologies
• Windows/Web/Cross platform mobile
developer
• Blogger, Speaker, Amateur photographer,
Gadget freak
2
Objective
• What is EF Core ?
• Why EF Core ?
• What it offers ?
• EF Core vs EF 6.x
• Demos
What is EF Core ?
• Entity Framework (EF) Core is an object-relational mapper (O/RM)
that enables .NET developers to work with a database using .NET
objects.
• EF Core is a lightweight and extensible version of the popular Entity
Framework data access technology.
Why EF Core ?
• Cross platform i.e., EF Core works on Windows/Mac/Linux
• Lightweight and Composable
• Supports new data stores (relational & non-relational)
• Multiple Database providers
• Optimized around being a simple intuitive O/RM
What it offers?
• Modelling
• Change Tracking
• SaveChanges
• Querying
• Database Schema Management
• Database Providers
• Platforms
Modelling
• Basic modelling
• Built in conventions
• Fluent API
• Data Annotations
• Relationships
• Shadow state properties
• Model validation
• Key Value generation
• Relational : Table mapping
• TPH inheritance
Change Tracking
• Snapshot change tracking
• Notification change tracking
• Accessing tracked state
• Via DbContext.Entry/DbContext.ChangeTracker
• Attaching detached entities/graphs
• Via DbContext.AttachGraph API
Save Changes
• Basic Save
• Optimistic Concurrency
• Async Save changes
• Transactions
• Relational : Batching of statements
Querying
• LINQ Support
• Mixed client/server evaluation
• NoTracking
• Eager loading
• Async Query
• Raw SQL Queries
• Via DbSet.FromSql
Database Schema Management
• Database Creation/Deletion
• Relational Database migration
• Reverse Engineer from Database
Database Providers
• Microsoft SqlServer – connects to SQL server 2008 onwards
• Microsoft SqlServer Compact edition
• IBM data servers
• Sqlite
• InMemory
• Postgres
• MySQL, Oracle (Coming soon)
Platforms
• Full .Net
• Console, WPF, WinForms, ASP.NET 4
• .Net Core
• Asp.Net Core on Windows, Linux and OS X
• UWP
EF Core vs EF 6.x
What’s new in EF Core ?
• Support for UWP, Asp.Net Core, Xamarin (coming soon)
• Database providers like InMemory, Azure Table storage, Redis etc.,
• Reverse engineer model from command line (Scaffold-DbContext)
• Shadow state properties
• Alternate Keys, Key generation at Client
• Mixed client/server evaluation
• Batching of statements (only relational)
What’s NOT available in EF Core ?
• Inheritance (Table per type, Table per concrete class)
• Many to many without join entities
• Complex/value types, Spatial data, graphical visualization of model,
Drag and drop editor, EDMX
• Reverse engineer from database (VS Wizard), Incremental model
update from DB
• Lazy loading, explicit loading, Stored Procedure
• Seed data, Connection resiliency, lifecycle hooks (events, command
interception etc.,)
Demo
Useful links
• https://github.com/aspnet/EntityFramework/wiki/Roadmap
• https://github.com/aspnet/EntityFramework/wiki/Guiding-Principles
• https://docs.efproject.net/en/latest/intro.html
• https://docs.efproject.net/en/latest/efcore-vs-
ef6/features.html#side-by-side-comparison
Thank You
Questions/Feedbacks : swami@wannabeegeek.com | @svswaminathan

More Related Content

What's hot

Migration from ASP.NET MVC to ASP.NET Core
Migration from ASP.NET MVC to ASP.NET CoreMigration from ASP.NET MVC to ASP.NET Core
Migration from ASP.NET MVC to ASP.NET Core
Miroslav Popovic
 
.Net Fundamentals
.Net Fundamentals.Net Fundamentals
.Net Fundamentals
Sunny Sharma
 
Mule ESB Intro
Mule ESB IntroMule ESB Intro
Mule ESB Intro
Noga Manela
 
WordPress Architecture For Beginners
WordPress Architecture For Beginners WordPress Architecture For Beginners
WordPress Architecture For Beginners
Tortoise and Hare Software
 
Zarafa SummerCamp 2012 - Exchange Web Services on Zarafa
Zarafa SummerCamp 2012 - Exchange Web Services on ZarafaZarafa SummerCamp 2012 - Exchange Web Services on Zarafa
Zarafa SummerCamp 2012 - Exchange Web Services on ZarafaZarafa
 
Life of our small product
Life of our small productLife of our small product
Life of our small product
Kenji HASUNUMA
 
.NET MeetUp Amsterdam 2017 - Challenges of Managing CoreFX repo -- Karel Zikmund
.NET MeetUp Amsterdam 2017 - Challenges of Managing CoreFX repo -- Karel Zikmund.NET MeetUp Amsterdam 2017 - Challenges of Managing CoreFX repo -- Karel Zikmund
.NET MeetUp Amsterdam 2017 - Challenges of Managing CoreFX repo -- Karel Zikmund
Karel Zikmund
 
Asp.Net 3 5 Part 1
Asp.Net 3 5 Part 1Asp.Net 3 5 Part 1
Asp.Net 3 5 Part 1
asim78
 
Web programming
Web programmingWeb programming
Web programming
Ishucs
 
Uniqueness of java
Uniqueness of javaUniqueness of java
Uniqueness of java
Sandeep Pandey
 
eGrove Systems Review - "Features of Magento 2.0"
eGrove Systems Review - "Features of Magento 2.0"eGrove Systems Review - "Features of Magento 2.0"
eGrove Systems Review - "Features of Magento 2.0"
Egrove Systems Corporation
 
KnowItPresentation
KnowItPresentationKnowItPresentation
KnowItPresentation
Chuan Su
 
Moving to the Cloud: AWS, Zend, RightScale
Moving to the Cloud: AWS, Zend, RightScaleMoving to the Cloud: AWS, Zend, RightScale
Moving to the Cloud: AWS, Zend, RightScalemmoline
 
Accelerating Devops using Corestack
Accelerating Devops using CorestackAccelerating Devops using Corestack
Accelerating Devops using Corestack
CoreStack
 
Corestack accelerating devops
Corestack accelerating devopsCorestack accelerating devops
Corestack accelerating devops
Anu Ravindranath
 
The future of cloud programming
The future of cloud programmingThe future of cloud programming
The future of cloud programming
Jason Straughan
 
Real World Rails Deployment
Real World Rails DeploymentReal World Rails Deployment
Real World Rails Deployment
Alan Hecht
 
eGrove Systems - "SOLR" An Apache Product
eGrove Systems - "SOLR" An Apache ProducteGrove Systems - "SOLR" An Apache Product
eGrove Systems - "SOLR" An Apache Product
Egrove Systems Corporation
 

What's hot (20)

Migration from ASP.NET MVC to ASP.NET Core
Migration from ASP.NET MVC to ASP.NET CoreMigration from ASP.NET MVC to ASP.NET Core
Migration from ASP.NET MVC to ASP.NET Core
 
.Net Fundamentals
.Net Fundamentals.Net Fundamentals
.Net Fundamentals
 
Mule ESB Intro
Mule ESB IntroMule ESB Intro
Mule ESB Intro
 
WordPress Architecture For Beginners
WordPress Architecture For Beginners WordPress Architecture For Beginners
WordPress Architecture For Beginners
 
Zarafa SummerCamp 2012 - Exchange Web Services on Zarafa
Zarafa SummerCamp 2012 - Exchange Web Services on ZarafaZarafa SummerCamp 2012 - Exchange Web Services on Zarafa
Zarafa SummerCamp 2012 - Exchange Web Services on Zarafa
 
Life of our small product
Life of our small productLife of our small product
Life of our small product
 
.NET MeetUp Amsterdam 2017 - Challenges of Managing CoreFX repo -- Karel Zikmund
.NET MeetUp Amsterdam 2017 - Challenges of Managing CoreFX repo -- Karel Zikmund.NET MeetUp Amsterdam 2017 - Challenges of Managing CoreFX repo -- Karel Zikmund
.NET MeetUp Amsterdam 2017 - Challenges of Managing CoreFX repo -- Karel Zikmund
 
FatDB Intro
FatDB IntroFatDB Intro
FatDB Intro
 
Asp.Net 3 5 Part 1
Asp.Net 3 5 Part 1Asp.Net 3 5 Part 1
Asp.Net 3 5 Part 1
 
Web programming
Web programmingWeb programming
Web programming
 
Velocity - Edge UG
Velocity - Edge UGVelocity - Edge UG
Velocity - Edge UG
 
Uniqueness of java
Uniqueness of javaUniqueness of java
Uniqueness of java
 
eGrove Systems Review - "Features of Magento 2.0"
eGrove Systems Review - "Features of Magento 2.0"eGrove Systems Review - "Features of Magento 2.0"
eGrove Systems Review - "Features of Magento 2.0"
 
KnowItPresentation
KnowItPresentationKnowItPresentation
KnowItPresentation
 
Moving to the Cloud: AWS, Zend, RightScale
Moving to the Cloud: AWS, Zend, RightScaleMoving to the Cloud: AWS, Zend, RightScale
Moving to the Cloud: AWS, Zend, RightScale
 
Accelerating Devops using Corestack
Accelerating Devops using CorestackAccelerating Devops using Corestack
Accelerating Devops using Corestack
 
Corestack accelerating devops
Corestack accelerating devopsCorestack accelerating devops
Corestack accelerating devops
 
The future of cloud programming
The future of cloud programmingThe future of cloud programming
The future of cloud programming
 
Real World Rails Deployment
Real World Rails DeploymentReal World Rails Deployment
Real World Rails Deployment
 
eGrove Systems - "SOLR" An Apache Product
eGrove Systems - "SOLR" An Apache ProducteGrove Systems - "SOLR" An Apache Product
eGrove Systems - "SOLR" An Apache Product
 

Similar to Entity Framework for Cross platform apps

Introduction to ASP.NET 5
Introduction to ASP.NET 5Introduction to ASP.NET 5
Introduction to ASP.NET 5
mbaric
 
Entity Core with Core Microservices.pptx
Entity Core with Core Microservices.pptxEntity Core with Core Microservices.pptx
Entity Core with Core Microservices.pptx
Knoldus Inc.
 
WSO2 Intro Webinar - Simplifying Enterprise Integration with Configurable WS...
WSO2 Intro Webinar -  Simplifying Enterprise Integration with Configurable WS...WSO2 Intro Webinar -  Simplifying Enterprise Integration with Configurable WS...
WSO2 Intro Webinar - Simplifying Enterprise Integration with Configurable WS...WSO2
 
.NET MeetUp Brno - Challenges of Managing CoreFX repo -- Karel Zikmund
.NET MeetUp Brno - Challenges of Managing CoreFX repo -- Karel Zikmund.NET MeetUp Brno - Challenges of Managing CoreFX repo -- Karel Zikmund
.NET MeetUp Brno - Challenges of Managing CoreFX repo -- Karel Zikmund
Karel Zikmund
 
ASP.NET 5
ASP.NET 5ASP.NET 5
ASP.NET 5
David Voyles
 
.NET MeetUp Prague 2017 - Challenges of Managing CoreFX repo -- Karel Zikmund
.NET MeetUp Prague 2017 - Challenges of Managing CoreFX repo -- Karel Zikmund.NET MeetUp Prague 2017 - Challenges of Managing CoreFX repo -- Karel Zikmund
.NET MeetUp Prague 2017 - Challenges of Managing CoreFX repo -- Karel Zikmund
Karel Zikmund
 
IBM Connect 2017: Your Data In the Major Leagues: A Practical Guide to REST S...
IBM Connect 2017: Your Data In the Major Leagues: A Practical Guide to REST S...IBM Connect 2017: Your Data In the Major Leagues: A Practical Guide to REST S...
IBM Connect 2017: Your Data In the Major Leagues: A Practical Guide to REST S...
Serdar Basegmez
 
[Research] azure ml anatomy of a machine learning service - Sharat Chikkerur
[Research] azure ml  anatomy of a machine learning service - Sharat Chikkerur[Research] azure ml  anatomy of a machine learning service - Sharat Chikkerur
[Research] azure ml anatomy of a machine learning service - Sharat Chikkerur
PAPIs.io
 
Entity framework introduction sesion-1
Entity framework introduction   sesion-1Entity framework introduction   sesion-1
Entity framework introduction sesion-1
Usama Nada
 
70487.pdf
70487.pdf70487.pdf
70487.pdf
Karen Benoit
 
Unboxing ASP.NET Core
Unboxing ASP.NET CoreUnboxing ASP.NET Core
Unboxing ASP.NET Core
Kevin Leung
 
Ektron 8.5 Web Content Managemnt
Ektron 8.5 Web Content ManagemntEktron 8.5 Web Content Managemnt
Ektron 8.5 Web Content ManagemntSean_OLeary
 
Alfresco Summit 2014 - Crafter CMS - Case European Bank
Alfresco Summit 2014 - Crafter CMS - Case European BankAlfresco Summit 2014 - Crafter CMS - Case European Bank
Alfresco Summit 2014 - Crafter CMS - Case European Bank
Piergiorgio Lucidi
 
Cloud compiler - Minor Project by students of CBPGEC
Cloud compiler - Minor Project by students of CBPGEC  Cloud compiler - Minor Project by students of CBPGEC
Cloud compiler - Minor Project by students of CBPGEC
vipin kumar
 
How to grow your own Microservice?
How to grow your own Microservice?How to grow your own Microservice?
How to grow your own Microservice?
Dmitry Buzdin
 
Escaping the yellow bubble - rewriting Domino using MongoDb and Angular
Escaping the yellow bubble - rewriting Domino using MongoDb and AngularEscaping the yellow bubble - rewriting Domino using MongoDb and Angular
Escaping the yellow bubble - rewriting Domino using MongoDb and Angular
Mark Leusink
 

Similar to Entity Framework for Cross platform apps (20)

Introduction to ASP.NET 5
Introduction to ASP.NET 5Introduction to ASP.NET 5
Introduction to ASP.NET 5
 
Entity Core with Core Microservices.pptx
Entity Core with Core Microservices.pptxEntity Core with Core Microservices.pptx
Entity Core with Core Microservices.pptx
 
WSO2 Intro Webinar - Simplifying Enterprise Integration with Configurable WS...
WSO2 Intro Webinar -  Simplifying Enterprise Integration with Configurable WS...WSO2 Intro Webinar -  Simplifying Enterprise Integration with Configurable WS...
WSO2 Intro Webinar - Simplifying Enterprise Integration with Configurable WS...
 
.NET MeetUp Brno - Challenges of Managing CoreFX repo -- Karel Zikmund
.NET MeetUp Brno - Challenges of Managing CoreFX repo -- Karel Zikmund.NET MeetUp Brno - Challenges of Managing CoreFX repo -- Karel Zikmund
.NET MeetUp Brno - Challenges of Managing CoreFX repo -- Karel Zikmund
 
ASP.NET 5
ASP.NET 5ASP.NET 5
ASP.NET 5
 
.NET MeetUp Prague 2017 - Challenges of Managing CoreFX repo -- Karel Zikmund
.NET MeetUp Prague 2017 - Challenges of Managing CoreFX repo -- Karel Zikmund.NET MeetUp Prague 2017 - Challenges of Managing CoreFX repo -- Karel Zikmund
.NET MeetUp Prague 2017 - Challenges of Managing CoreFX repo -- Karel Zikmund
 
IBM Connect 2017: Your Data In the Major Leagues: A Practical Guide to REST S...
IBM Connect 2017: Your Data In the Major Leagues: A Practical Guide to REST S...IBM Connect 2017: Your Data In the Major Leagues: A Practical Guide to REST S...
IBM Connect 2017: Your Data In the Major Leagues: A Practical Guide to REST S...
 
[Research] azure ml anatomy of a machine learning service - Sharat Chikkerur
[Research] azure ml  anatomy of a machine learning service - Sharat Chikkerur[Research] azure ml  anatomy of a machine learning service - Sharat Chikkerur
[Research] azure ml anatomy of a machine learning service - Sharat Chikkerur
 
Entity framework introduction sesion-1
Entity framework introduction   sesion-1Entity framework introduction   sesion-1
Entity framework introduction sesion-1
 
70487.pdf
70487.pdf70487.pdf
70487.pdf
 
Unboxing ASP.NET Core
Unboxing ASP.NET CoreUnboxing ASP.NET Core
Unboxing ASP.NET Core
 
Ektron 8.5 Web Content Managemnt
Ektron 8.5 Web Content ManagemntEktron 8.5 Web Content Managemnt
Ektron 8.5 Web Content Managemnt
 
Oracle bi apps training
Oracle bi apps trainingOracle bi apps training
Oracle bi apps training
 
Alfresco Summit 2014 - Crafter CMS - Case European Bank
Alfresco Summit 2014 - Crafter CMS - Case European BankAlfresco Summit 2014 - Crafter CMS - Case European Bank
Alfresco Summit 2014 - Crafter CMS - Case European Bank
 
Cloud compiler - Minor Project by students of CBPGEC
Cloud compiler - Minor Project by students of CBPGEC  Cloud compiler - Minor Project by students of CBPGEC
Cloud compiler - Minor Project by students of CBPGEC
 
05 entity framework
05 entity framework05 entity framework
05 entity framework
 
Sharepoint Deployments
Sharepoint DeploymentsSharepoint Deployments
Sharepoint Deployments
 
How to grow your own Microservice?
How to grow your own Microservice?How to grow your own Microservice?
How to grow your own Microservice?
 
Escaping the yellow bubble - rewriting Domino using MongoDb and Angular
Escaping the yellow bubble - rewriting Domino using MongoDb and AngularEscaping the yellow bubble - rewriting Domino using MongoDb and Angular
Escaping the yellow bubble - rewriting Domino using MongoDb and Angular
 
Express yourself
Express yourselfExpress yourself
Express yourself
 

More from Swaminathan Vetri

Architecting multi-cloud ready applications
Architecting multi-cloud ready applicationsArchitecting multi-cloud ready applications
Architecting multi-cloud ready applications
Swaminathan Vetri
 
BDotNet - Microsoft Build 2023 After Party
BDotNet - Microsoft Build 2023 After Party BDotNet - Microsoft Build 2023 After Party
BDotNet - Microsoft Build 2023 After Party
Swaminathan Vetri
 
AzureContainerAppswithDotNet_Pune_2022.pptx
AzureContainerAppswithDotNet_Pune_2022.pptxAzureContainerAppswithDotNet_Pune_2022.pptx
AzureContainerAppswithDotNet_Pune_2022.pptx
Swaminathan Vetri
 
Microservices and Service Mesh
Microservices and Service MeshMicroservices and Service Mesh
Microservices and Service Mesh
Swaminathan Vetri
 
Infrastructure automation with .NET
Infrastructure automation with .NETInfrastructure automation with .NET
Infrastructure automation with .NET
Swaminathan Vetri
 
Azure infra automation using pulumi
Azure infra automation using pulumiAzure infra automation using pulumi
Azure infra automation using pulumi
Swaminathan Vetri
 
CI/CD with GitHub Actions
CI/CD with GitHub ActionsCI/CD with GitHub Actions
CI/CD with GitHub Actions
Swaminathan Vetri
 
Bye bye WCF, hello gRPC
Bye bye WCF, hello gRPCBye bye WCF, hello gRPC
Bye bye WCF, hello gRPC
Swaminathan Vetri
 
Building cloud native apps
Building cloud native appsBuilding cloud native apps
Building cloud native apps
Swaminathan Vetri
 
Azure dev ops
Azure dev opsAzure dev ops
Azure dev ops
Swaminathan Vetri
 
.Net Standard 2.0
.Net Standard 2.0.Net Standard 2.0
.Net Standard 2.0
Swaminathan Vetri
 
Cross platform dotnet development using dotnet core
Cross platform dotnet development using dotnet coreCross platform dotnet development using dotnet core
Cross platform dotnet development using dotnet core
Swaminathan Vetri
 
Unicom DevCon - CI/CD for Asp.net core apps using Docker
Unicom DevCon - CI/CD for Asp.net core apps using DockerUnicom DevCon - CI/CD for Asp.net core apps using Docker
Unicom DevCon - CI/CD for Asp.net core apps using Docker
Swaminathan Vetri
 
CI/CD for Asp.net core apps using Docker
CI/CD for Asp.net core apps using DockerCI/CD for Asp.net core apps using Docker
CI/CD for Asp.net core apps using Docker
Swaminathan Vetri
 
Deploying .net core apps to Docker - dotnetConf Local Bengaluru
Deploying .net core apps to Docker - dotnetConf Local BengaluruDeploying .net core apps to Docker - dotnetConf Local Bengaluru
Deploying .net core apps to Docker - dotnetConf Local Bengaluru
Swaminathan Vetri
 
Rapid mobile app development using Ionic framework
Rapid mobile app development using Ionic frameworkRapid mobile app development using Ionic framework
Rapid mobile app development using Ionic framework
Swaminathan Vetri
 
Xamarin Dev Days - Intro to Xamarin
Xamarin Dev Days - Intro to XamarinXamarin Dev Days - Intro to Xamarin
Xamarin Dev Days - Intro to Xamarin
Swaminathan Vetri
 
Getting Started with Ionic
Getting Started with IonicGetting Started with Ionic
Getting Started with Ionic
Swaminathan Vetri
 

More from Swaminathan Vetri (18)

Architecting multi-cloud ready applications
Architecting multi-cloud ready applicationsArchitecting multi-cloud ready applications
Architecting multi-cloud ready applications
 
BDotNet - Microsoft Build 2023 After Party
BDotNet - Microsoft Build 2023 After Party BDotNet - Microsoft Build 2023 After Party
BDotNet - Microsoft Build 2023 After Party
 
AzureContainerAppswithDotNet_Pune_2022.pptx
AzureContainerAppswithDotNet_Pune_2022.pptxAzureContainerAppswithDotNet_Pune_2022.pptx
AzureContainerAppswithDotNet_Pune_2022.pptx
 
Microservices and Service Mesh
Microservices and Service MeshMicroservices and Service Mesh
Microservices and Service Mesh
 
Infrastructure automation with .NET
Infrastructure automation with .NETInfrastructure automation with .NET
Infrastructure automation with .NET
 
Azure infra automation using pulumi
Azure infra automation using pulumiAzure infra automation using pulumi
Azure infra automation using pulumi
 
CI/CD with GitHub Actions
CI/CD with GitHub ActionsCI/CD with GitHub Actions
CI/CD with GitHub Actions
 
Bye bye WCF, hello gRPC
Bye bye WCF, hello gRPCBye bye WCF, hello gRPC
Bye bye WCF, hello gRPC
 
Building cloud native apps
Building cloud native appsBuilding cloud native apps
Building cloud native apps
 
Azure dev ops
Azure dev opsAzure dev ops
Azure dev ops
 
.Net Standard 2.0
.Net Standard 2.0.Net Standard 2.0
.Net Standard 2.0
 
Cross platform dotnet development using dotnet core
Cross platform dotnet development using dotnet coreCross platform dotnet development using dotnet core
Cross platform dotnet development using dotnet core
 
Unicom DevCon - CI/CD for Asp.net core apps using Docker
Unicom DevCon - CI/CD for Asp.net core apps using DockerUnicom DevCon - CI/CD for Asp.net core apps using Docker
Unicom DevCon - CI/CD for Asp.net core apps using Docker
 
CI/CD for Asp.net core apps using Docker
CI/CD for Asp.net core apps using DockerCI/CD for Asp.net core apps using Docker
CI/CD for Asp.net core apps using Docker
 
Deploying .net core apps to Docker - dotnetConf Local Bengaluru
Deploying .net core apps to Docker - dotnetConf Local BengaluruDeploying .net core apps to Docker - dotnetConf Local Bengaluru
Deploying .net core apps to Docker - dotnetConf Local Bengaluru
 
Rapid mobile app development using Ionic framework
Rapid mobile app development using Ionic frameworkRapid mobile app development using Ionic framework
Rapid mobile app development using Ionic framework
 
Xamarin Dev Days - Intro to Xamarin
Xamarin Dev Days - Intro to XamarinXamarin Dev Days - Intro to Xamarin
Xamarin Dev Days - Intro to Xamarin
 
Getting Started with Ionic
Getting Started with IonicGetting Started with Ionic
Getting Started with Ionic
 

Recently uploaded

GraphSummit Singapore | The Art of the Possible with Graph - Q2 2024
GraphSummit Singapore | The Art of the  Possible with Graph - Q2 2024GraphSummit Singapore | The Art of the  Possible with Graph - Q2 2024
GraphSummit Singapore | The Art of the Possible with Graph - Q2 2024
Neo4j
 
GridMate - End to end testing is a critical piece to ensure quality and avoid...
GridMate - End to end testing is a critical piece to ensure quality and avoid...GridMate - End to end testing is a critical piece to ensure quality and avoid...
GridMate - End to end testing is a critical piece to ensure quality and avoid...
ThomasParaiso2
 
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
Neo4j
 
Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1
DianaGray10
 
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptx
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptxSecstrike : Reverse Engineering & Pwnable tools for CTF.pptx
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptx
nkrafacyberclub
 
Pushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 daysPushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 days
Adtran
 
By Design, not by Accident - Agile Venture Bolzano 2024
By Design, not by Accident - Agile Venture Bolzano 2024By Design, not by Accident - Agile Venture Bolzano 2024
By Design, not by Accident - Agile Venture Bolzano 2024
Pierluigi Pugliese
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
Safe Software
 
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
James Anderson
 
Microsoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdfMicrosoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdf
Uni Systems S.M.S.A.
 
UiPath Test Automation using UiPath Test Suite series, part 6
UiPath Test Automation using UiPath Test Suite series, part 6UiPath Test Automation using UiPath Test Suite series, part 6
UiPath Test Automation using UiPath Test Suite series, part 6
DianaGray10
 
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
Neo4j
 
Epistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI supportEpistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI support
Alan Dix
 
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
SOFTTECHHUB
 
PCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase TeamPCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase Team
ControlCase
 
Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?
Nexer Digital
 
Uni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdfUni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems S.M.S.A.
 
Large Language Model (LLM) and it’s Geospatial Applications
Large Language Model (LLM) and it’s Geospatial ApplicationsLarge Language Model (LLM) and it’s Geospatial Applications
Large Language Model (LLM) and it’s Geospatial Applications
Rohit Gautam
 
Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
KatiaHIMEUR1
 
Monitoring Java Application Security with JDK Tools and JFR Events
Monitoring Java Application Security with JDK Tools and JFR EventsMonitoring Java Application Security with JDK Tools and JFR Events
Monitoring Java Application Security with JDK Tools and JFR Events
Ana-Maria Mihalceanu
 

Recently uploaded (20)

GraphSummit Singapore | The Art of the Possible with Graph - Q2 2024
GraphSummit Singapore | The Art of the  Possible with Graph - Q2 2024GraphSummit Singapore | The Art of the  Possible with Graph - Q2 2024
GraphSummit Singapore | The Art of the Possible with Graph - Q2 2024
 
GridMate - End to end testing is a critical piece to ensure quality and avoid...
GridMate - End to end testing is a critical piece to ensure quality and avoid...GridMate - End to end testing is a critical piece to ensure quality and avoid...
GridMate - End to end testing is a critical piece to ensure quality and avoid...
 
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
 
Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1
 
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptx
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptxSecstrike : Reverse Engineering & Pwnable tools for CTF.pptx
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptx
 
Pushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 daysPushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 days
 
By Design, not by Accident - Agile Venture Bolzano 2024
By Design, not by Accident - Agile Venture Bolzano 2024By Design, not by Accident - Agile Venture Bolzano 2024
By Design, not by Accident - Agile Venture Bolzano 2024
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
 
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
 
Microsoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdfMicrosoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdf
 
UiPath Test Automation using UiPath Test Suite series, part 6
UiPath Test Automation using UiPath Test Suite series, part 6UiPath Test Automation using UiPath Test Suite series, part 6
UiPath Test Automation using UiPath Test Suite series, part 6
 
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
 
Epistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI supportEpistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI support
 
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
 
PCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase TeamPCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase Team
 
Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?
 
Uni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdfUni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdf
 
Large Language Model (LLM) and it’s Geospatial Applications
Large Language Model (LLM) and it’s Geospatial ApplicationsLarge Language Model (LLM) and it’s Geospatial Applications
Large Language Model (LLM) and it’s Geospatial Applications
 
Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
 
Monitoring Java Application Security with JDK Tools and JFR Events
Monitoring Java Application Security with JDK Tools and JFR EventsMonitoring Java Application Security with JDK Tools and JFR Events
Monitoring Java Application Security with JDK Tools and JFR Events
 

Entity Framework for Cross platform apps

  • 1. EF For Cross Platform Apps @svswaminathan BDotNet UG Meet, Aug 2016
  • 2. Swaminathan Vetri • Senior Engineer @ Target • Microsoft MVP - Visual Studio & Development technologies • Windows/Web/Cross platform mobile developer • Blogger, Speaker, Amateur photographer, Gadget freak 2
  • 3. Objective • What is EF Core ? • Why EF Core ? • What it offers ? • EF Core vs EF 6.x • Demos
  • 4. What is EF Core ? • Entity Framework (EF) Core is an object-relational mapper (O/RM) that enables .NET developers to work with a database using .NET objects. • EF Core is a lightweight and extensible version of the popular Entity Framework data access technology.
  • 5. Why EF Core ? • Cross platform i.e., EF Core works on Windows/Mac/Linux • Lightweight and Composable • Supports new data stores (relational & non-relational) • Multiple Database providers • Optimized around being a simple intuitive O/RM
  • 6. What it offers? • Modelling • Change Tracking • SaveChanges • Querying • Database Schema Management • Database Providers • Platforms
  • 7. Modelling • Basic modelling • Built in conventions • Fluent API • Data Annotations • Relationships • Shadow state properties • Model validation • Key Value generation • Relational : Table mapping • TPH inheritance
  • 8. Change Tracking • Snapshot change tracking • Notification change tracking • Accessing tracked state • Via DbContext.Entry/DbContext.ChangeTracker • Attaching detached entities/graphs • Via DbContext.AttachGraph API
  • 9. Save Changes • Basic Save • Optimistic Concurrency • Async Save changes • Transactions • Relational : Batching of statements
  • 10. Querying • LINQ Support • Mixed client/server evaluation • NoTracking • Eager loading • Async Query • Raw SQL Queries • Via DbSet.FromSql
  • 11. Database Schema Management • Database Creation/Deletion • Relational Database migration • Reverse Engineer from Database
  • 12. Database Providers • Microsoft SqlServer – connects to SQL server 2008 onwards • Microsoft SqlServer Compact edition • IBM data servers • Sqlite • InMemory • Postgres • MySQL, Oracle (Coming soon)
  • 13. Platforms • Full .Net • Console, WPF, WinForms, ASP.NET 4 • .Net Core • Asp.Net Core on Windows, Linux and OS X • UWP
  • 14. EF Core vs EF 6.x
  • 15. What’s new in EF Core ? • Support for UWP, Asp.Net Core, Xamarin (coming soon) • Database providers like InMemory, Azure Table storage, Redis etc., • Reverse engineer model from command line (Scaffold-DbContext) • Shadow state properties • Alternate Keys, Key generation at Client • Mixed client/server evaluation • Batching of statements (only relational)
  • 16. What’s NOT available in EF Core ? • Inheritance (Table per type, Table per concrete class) • Many to many without join entities • Complex/value types, Spatial data, graphical visualization of model, Drag and drop editor, EDMX • Reverse engineer from database (VS Wizard), Incremental model update from DB • Lazy loading, explicit loading, Stored Procedure • Seed data, Connection resiliency, lifecycle hooks (events, command interception etc.,)
  • 17. Demo
  • 18. Useful links • https://github.com/aspnet/EntityFramework/wiki/Roadmap • https://github.com/aspnet/EntityFramework/wiki/Guiding-Principles • https://docs.efproject.net/en/latest/intro.html • https://docs.efproject.net/en/latest/efcore-vs- ef6/features.html#side-by-side-comparison
  • 19. Thank You Questions/Feedbacks : swami@wannabeegeek.com | @svswaminathan

Editor's Notes

  1. LW & composable – built with CPU and memory in mind, built over composable blocks, pay-per-play, avoid unnecessary abstractions between top level API & DB New data stores – Enables O/RM like features to be applied for non-relational ones, its NOT a replacement for noSQL SDK Optimized for simple O/RM – not a micro O/RM, encourages a specific way of doing things, you can always go back to plain SQL when required
  2. Shadow Properties : These do not exist in the model class, used purely for change tracking
  3. Optimistic Concurrency – protects against overrides from other user’s changes Transactions – to make sure changes are atomic
  4. No tracking – for results that are read only ; doesn’t monitor the changes for the entities
  5. DB creation/deletion APIs to quickly test DB without using migrations
  6. Connection resiliency – automatically retries database commands on failure (more for sql azure kind of scenarios)