Browse Source

Create v10.2 migration guide

pull/24938/head
EngincanV 1 month ago
parent
commit
bf20b1e7a3
  1. 118
      docs/en/release-info/migration-guides/abp-10-2.md
  2. 1
      docs/en/release-info/migration-guides/index.md

118
docs/en/release-info/migration-guides/abp-10-2.md

@ -0,0 +1,118 @@
```json
//[doc-seo]
{
"Description": "Upgrade your ABP solutions from v10.1 to v10.2 with this comprehensive migration guide, ensuring compatibility and new features with ABP v10.2."
}
```
# ABP Version 10.2 Migration Guide
This document is a guide for upgrading ABP v10.1 solutions to ABP v10.2. There are some changes in this version that may affect your applications. Please read them carefully and apply the necessary changes to your application.
> **Package Version Changes:** Before upgrading, review the [Package Version Changes](../../package-version-changes.md) document to see version changes on dependent NuGet packages and align your project with ABP's internal package versions.
## Open-Source (Framework)
This version only requires changes on the open-source side. **There are no breaking changes on the PRO side.**
### Add New EF Core Migrations for Audit Logging Module
In this version, we increased the maximum length limits for entity and property type full names in the [Audit Logging Module](../../modules/audit-logging.md) from 128/64/192 to 512 characters. This reduces truncation risk when persisting entity/property type information for entities with long CLR type names.
**If you are using the Audit Logging module with Entity Framework Core, you need to create a new EF Core migration and apply it to your database** after upgrading to ABP 10.2.
> See [#24846](https://github.com/abpframework/abp/pull/24846) for more details.
### Ambient Auditing Disable/Enable Support
In this version, we added ambient auditing disable/enable support to the ABP Framework. The `IAuditingHelper` interface now includes `DisableAuditing()` and `IsAuditingEnabled()` methods, allowing you to temporarily disable auditing for specific code blocks using a disposable scope pattern.
**Action required:** If you have custom code that extends or overrides `CmsKitPageRouteValueTransformer`, note that it now injects `IAuditingHelper` to disable auditing during route matching. You may need to update your constructor to accept the new dependency.
For most applications, no changes are required. The new API is additive and can be used when you need to disable auditing programmatically:
```csharp
using (var scope = _auditingHelper.DisableAuditing())
{
// Auditing is disabled within this block
}
```
> See [#24718](https://github.com/abpframework/abp/pull/24718) for more details.
### TickerQ Package Upgrade (2.5.3 → 10.1.1)
**If you are using the TickerQ integration packages** (`Volo.Abp.TickerQ`, `Volo.Abp.BackgroundJobs.TickerQ`, or `Volo.Abp.BackgroundWorkers.TickerQ`), you need to apply the following breaking changes. TickerQ 10.1.1 only targets `net10.0` and contains several API changes.
#### UseAbpTickerQ moved from IApplicationBuilder to IHost
`UseAbpTickerQ` is now an extension on `IHost` (namespace `Microsoft.Extensions.Hosting`). Update your `OnApplicationInitializationAsync` method:
```csharp
// Before
public override async Task OnApplicationInitializationAsync(ApplicationInitializationContext context)
{
context.GetApplicationBuilder().UseAbpTickerQ();
}
// After
public override async Task OnApplicationInitializationAsync(ApplicationInitializationContext context)
{
context.GetHost().UseAbpTickerQ();
}
```
> **Important:** Do **not** resolve `IHost` from `context.ServiceProvider.GetRequiredService<IHost>()`. That returns the internal generic host whose `Services` does not include `IApplicationBuilder`, which will cause a runtime exception from the TickerQ Dashboard. Always use `context.GetHost()`.
#### Entity types renamed
- `TimeTicker``TimeTickerEntity`
- `CronTicker``CronTickerEntity`
Update your `using` statements and type references from `TickerQ.Utilities.Models.Ticker` to `TickerQ.Utilities.Entities`.
#### TickerFunctionContext namespace moved
`TickerFunctionContext<T>` has moved from `TickerQ.Utilities.Models` to `TickerQ.Utilities.Base`.
#### TickerRequestProvider.GetRequestAsync signature changed
```csharp
// Before
var request = await TickerRequestProvider.GetRequestAsync<string>(serviceProvider, context.Id, context.Type);
// After
var request = await TickerRequestProvider.GetRequestAsync<string>(context, cancellationToken);
```
#### Scheduler configuration API changed
```csharp
// Before
options.SetInstanceIdentifier(name);
options.UpdateMissedJobCheckDelay(TimeSpan.FromSeconds(30));
// After
options.ConfigureScheduler(s => s.NodeIdentifier = name);
options.ConfigureScheduler(s => s.FallbackIntervalChecker = TimeSpan.FromSeconds(30));
```
#### Dashboard configuration API changed
```csharp
// Before
x.BasePath = "/tickerq";
x.UseHostAuthentication = true;
// After
x.SetBasePath("/tickerq");
x.WithHostAuthentication();
```
#### Other changes
- **Typo fix:** `result.IsSucceded``result.IsSucceeded`
- **BatchParent removed:** `TimeTickerEntity.ParentId` now has a private setter. Use TickerQ's `FluentChainTickerBuilder` fluent API for job chaining.
- **BatchRunCondition renamed:** `BatchRunCondition? BatchRunCondition``RunCondition? RunCondition` in `AbpBackgroundJobsTimeTickerConfiguration`
> See [#24916](https://github.com/abpframework/abp/pull/24916) for more details.

1
docs/en/release-info/migration-guides/index.md

@ -9,6 +9,7 @@
The following documents explain how to migrate your existing ABP applications. We write migration documents only if you need to take an action while upgrading your solution. Otherwise, you can easily upgrade your solution using the [abp update command](../upgrading.md).
- [10.x to 10.2](abp-10-2.md)
- [10.0 to 10.1](abp-10-1.md)
- [9.x to 10.0](abp-10-0.md)
- [9.2 to 9.3](abp-9-3.md)

Loading…
Cancel
Save