You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
Currently, the project uses the old seeding mechanism for database initialization and seeding. With the introduction of EF Core 9, there is a new UseAsyncSeeding method that provides a more efficient way to handle asynchronous database seeding. The current seeding logic does not take full advantage of these new capabilities.
Describe the solution you'd like
Refactor the database seeding logic to utilize the new UseAsyncSeeding method introduced in EF Core 9. Specifically, I would like to:
Implement an AddAsyncSeeding extension method to configure the DbContextOptionsBuilder for async seeding.
Refactor the ApplicationDbContextInitialiser to work with the new async seeding approach.
Ensure that default roles, users, and any necessary data (e.g., TodoList and TodoItem) are seeded correctly using the new method.
Update the AddDbContext configuration to use AddAsyncSeeding for all supported database providers (PostgreSQL, SQLite, and SQL Server).
Describe alternatives you've considered
An alternative would be to keep the current seeding mechanism and not update it for EF Core 9, but this would mean missing out on the performance and scalability improvements that come with async seeding.
Additional context
EF Core 9 introduces new features that allow for more efficient asynchronous workflows. Leveraging UseAsyncSeeding will ensure the seeding process is non-blocking and scales better with larger datasets. This change will also improve maintainability and clarity in the codebase by clearly separating database initialization and seeding logic.
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem? Please describe.
Currently, the project uses the old seeding mechanism for database initialization and seeding. With the introduction of EF Core 9, there is a new
UseAsyncSeeding
method that provides a more efficient way to handle asynchronous database seeding. The current seeding logic does not take full advantage of these new capabilities.Describe the solution you'd like
Refactor the database seeding logic to utilize the new
UseAsyncSeeding
method introduced in EF Core 9. Specifically, I would like to:AddAsyncSeeding
extension method to configure theDbContextOptionsBuilder
for async seeding.ApplicationDbContextInitialiser
to work with the new async seeding approach.TodoList
andTodoItem
) are seeded correctly using the new method.AddDbContext
configuration to useAddAsyncSeeding
for all supported database providers (PostgreSQL, SQLite, and SQL Server).Describe alternatives you've considered
An alternative would be to keep the current seeding mechanism and not update it for EF Core 9, but this would mean missing out on the performance and scalability improvements that come with async seeding.
Additional context
EF Core 9 introduces new features that allow for more efficient asynchronous workflows. Leveraging
UseAsyncSeeding
will ensure the seeding process is non-blocking and scales better with larger datasets. This change will also improve maintainability and clarity in the codebase by clearly separating database initialization and seeding logic.The text was updated successfully, but these errors were encountered: