Browse Source

Update Abp-8_0.md

pull/18154/head
maliming 3 years ago
parent
commit
087b81c3aa
No known key found for this signature in database GPG Key ID: A646B9CB645ECEA4
  1. 10
      docs/en/Migration-Guides/Abp-8_0.md

10
docs/en/Migration-Guides/Abp-8_0.md

@ -103,6 +103,16 @@ You don't need to make any changes related to that, however it's important to kn
In this version, `AbpAspNetCoreAsyncIntegratedTestBase` class has been set as `Obsolete` and it's recommended to use `AbpWebApplicationFactoryIntegratedTest` instead.
## Use NoTracking for readonly repositories for EF core.
ABP Framework provides read-only [repository](Repositories.md) interfaces (`IReadOnlyRepository<...>` or `IReadOnlyBasicRepository<...>`) to explicitly indicate that your purpose is to query data, but not change it. If so, you can inject these interfaces into your services.
Entity Framework Core read-only repository implementation uses [EF Core's No-Tracking feature](https://learn.microsoft.com/en-us/ef/core/querying/tracking#no-tracking-queries). That means the entities returned from the repository will not be tracked by the EF Core [change tracker](https://learn.microsoft.com/en-us/ef/core/change-tracking/), because it is expected that you won't update entities queried from a read-only repository.
> This behavior works only if the repository object is injected with one of the read-only repository interfaces (`IReadOnlyRepository<...>` or `IReadOnlyBasicRepository<...>`). It won't work if you have injected a standard repository (e.g. `IRepository<...>`) then casted it to a read-only repository interface.
> See the issue for more information: https://github.com/abpframework/abp/pull/17421
## Upgraded NuGet Dependencies
You can see the following list of NuGet libraries that have been upgraded with .NET 8.0 upgrade, if you are using one of these packages explicitly, you may consider upgrading them in your solution:

Loading…
Cancel
Save