menu
techminis

A naukri.com initiative

google-web-stories
Home

>

Programming News

>

The Truth ...
source image

Dev

3d

read

248

img
dot

Image Credit: Dev

The Truth About AddAsync: When to Use It in EF Core (and When Not To)

  • AddAsync() in EF Core does not talk to the database directly but tracks new entities for later insertion.
  • The main reason for using AddAsync() is for async value generation, such as generating unique IDs.
  • Using synchronous Add() can lead to blocking threads, affecting throughput in busy applications.
  • AddAsync() is recommended for scenarios involving custom async value generators, async-first apps, and high-scale services.

Read Full Article

like

14 Likes

For uninterrupted reading, download the app