entity framework query generation – linq-syntax – auto-compilation database access – single...
TRANSCRIPT
#justdotnetthings
Retooling a Legacy App
Entity Framework
• Query Generation– LINQ-syntax– Auto-compilation
• Database Access– Single context during page interaction
– —————— Less code– ———————— Better performance
– —————————————————
Some Page Some Page
What We Have Today
Some Page
-Factory
-Manager
-DAL
160+1
160+1
+1
-Collection160+1
• What if we need different data?
• What if we add a new database table?
-ServiceFaçade
ObjectSettings
What We’re Going For
-DbContext
Entity
Some Page
What We Have Today
Some Page
-Factory
-Manager
-DAL
160+1
160+1
+1
-Collection160+1
• What if we need different data?
• What if we add a new database table?
-ServiceFaçade
What We’re Going For
Deletable -DbContext
Creatable
SearchByDate
Entity
Some Page
• What if we need different data?
• What if we add a new database table?
SearchByName
+1
Aftermath
• Doesn’t this break literally everything?– Let’s do a demo
• What we’ve learned– You can’t spell “Hackathon” without “Hack”– Implementing a new framework isn’t a three day task
• But it can be done piece-by-piece