Talk | 
IT-Tage 2019
 | 09.12.2019

Entity Framework Core – Performanzoptimierung

Mit dem Entity Framework hat Microsoft vor Jahren einen Objekt-Relationalen-Mapper geschaffen, welcher sich in der .NET-Welt mittlerweile einer großen Beliebtheit erfreut. Der O/R-Mapper ermöglicht es, ohne SQL-Kenntnisse auf eine Datenbank sowohl lesend als auch schreibend zuzugreifen. Doch hier verbergen sich Risiken, denn ein O/R-Mapper erweckt den Eindruck, dass der Anwendungsentwickler sich nie wieder mit SQL zu befassen braucht - was für 80% der Abfragen in einer Anwendung auch stimmen mag. Die restlichen 20% können allerdings die gesamte Applikation durch sehr schlechte Antwortzeiten beinah unbenutzbar machen. Die unperformanten SQL-Abfragen sind jedoch nicht die einzige Quelle welche die Benutzbarkeit in Mitleidenschaft ziehen. Es spielt auch eine Rolle wie genau Entity Framework im Code verwendet wird. Nicht selten wird die Tatsache vergessen, dass die LINQ-Abfragen am Ende nicht im Arbeitsspeicher, sondern durch die Datenbank ausgeführt werden – mehr oder weniger „transparent“. In ersten Teil des Vortrags wird gezeigt auf was geachtet werden sollte, um die häufigsten Stolperfallen bei der Verwendung von Entity Framework Core zu vermeiden. Im zweiten Teil geht es darum, die generierten SQL-Abfragen zu verstehen, denn nur so kann das Problem erkannt und gelöst werden. Das wichtigste Mittel hierfür werden die Ausführungspläne sein.

Pawel Gerr ist Architekt und Consultant bei Thinktecture. Er hat sich auf .NET Core Backends spezialisiert und kennt Entity Framework von vorne bis hinten.

Event

IT-Tage 2019
09.12.19  
- 12.12.19 
@ Frankfurt
 (DE)
Entity Framework Core – Performanzoptimierung

Links & Materialien

Mehr Beiträge zu .NET Core, Entity Framework

Hallo, .NET Developer!

Du begeisterst Dich für .NET-basierte Cloud-Native-Lösungen?

Du möchtest, dass Deine Expertise zum Einsatz kommt und von einer Expertenschaft gechallenged wird? Du weißt, dass nur durch Research auch während der Arbeitszeit neue Technologien erlernbar sind und erst damit Innovation möglich wird?

Weitere Artikel zu .NET Core, Entity Framework

.NET
Incremental Roslyn Source Generators: High-Level API – ForAttributeWithMetadataName – Part 8

Incremental Roslyn Source Generators: High-Level API – ForAttributeWithMetadataName – Part 8

With the version 4.3.1 of Microsoft.CodeAnalysis.* Roslyn provides a new high-level API - the method "ForAttributeWithMetadataName". Although it is just 1 method, still, it addresses one of the biggest performance issue with Source Generators.
16.05.2023
.NET
.NET 7 Performance: Regular Expressions – Part 2

.NET 7 Performance: Regular Expressions – Part 2

There is this popular quote by Jamie Zawinski: Some people, when confronted with a problem, think "I know, I'll use regular expressions." Now they have two problems."

In this second article of our short performance series, we want to look at the latter one of those problems.
25.04.2023
.NET
.NET 7 Performance: Introduction and Runtime Optimizations – Part 1

.NET 7 Performance: Introduction and Runtime Optimizations – Part 1

.NET 7 is fast. Superfast. All the teams at Microsoft working on .NET are keen to improve the performance and do so every year with each new .NET release. Though this time the achievements are really impressive. In this series of short articles, we want to explore some of the most significant performance updates in .NET and look at how that may affect our own projects. This first article is taking a deep look under the hood of the compiler and the runtime to look for some remarkably interesting and significant updates.
28.03.2023
.NET
Incremental Roslyn Source Generators: Using Additional Files – Part 7

Incremental Roslyn Source Generators: Using Additional Files – Part 7

In the previous article the Source Generator itself needed a 3rd-party library Newtonsoft.Json in order to generate new source code. The JSON-strings were hard-coded inside the Source Generator for simplicity reasons. In this article we will see how to process not just .NET code, but also other files, like JSON or XML.
21.03.2023
Entity Framework
Entity Framework Core 7 Performance: Cartesian Explosion

Entity Framework Core 7 Performance: Cartesian Explosion

In Entity Framework Core 3 (EF 3) the SQL statement generation (re)introduced the Cartesian Explosion problem. A lot has happened since then, so it is time to revisit the issue with Entity Framework Core 7 (EF 7).
14.03.2023
.NET
Understanding and Controlling the Blazor WebAssembly Startup Process

Understanding and Controlling the Blazor WebAssembly Startup Process

There are a lot of things going on in the background, when a Blazor WebAssembly application is being started. In some cases you might want to take a bit more control over that process. One example might be the wish to display a loading screen for applications that take some time for initial preparation, or when users are on a slow internet connection. However, in order to control something, we need to understand what is happening first. This article takes you down the rabbit hole of how a Blazor WASM application starts up.
07.03.2023

Unsere Webinare

Unsere Artikel

Mehr über uns