From 0695237feb55c7e2ded1de570fbd0332a3e2ed53 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 16 Jul 2026 05:47:59 +0000 Subject: [PATCH 1/8] Initial plan From 79bb3b3423d00b44a920cfe3d177d5e2b34d329d Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 16 Jul 2026 06:05:03 +0000 Subject: [PATCH 2/8] Replace Pomelo with Microting.EntityFrameworkCore.MySql for .NET 10+ --- Directory.Packages.props | 12 +++++++----- ...istributedTransactions.CAP.MySql.UnitTests.csproj | 3 ++- ...ory.EntityFrameworkCore.Identity.UnitTests.csproj | 3 ++- ...s.Repository.EntityFrameworkCore.UnitTests.csproj | 3 ++- ...tCorePal.Extensions.ShardingCore.UnitTests.csproj | 3 ++- .../ShardingMySqlMigrationsSqlGenerator.cs | 5 +++++ test/NetCorePal.Web/NetCorePal.Web.csproj | 3 ++- 7 files changed, 22 insertions(+), 10 deletions(-) diff --git a/Directory.Packages.props b/Directory.Packages.props index b6978453..274d7bad 100644 --- a/Directory.Packages.props +++ b/Directory.Packages.props @@ -32,15 +32,16 @@ 10.0.0 10.0.0 - 9.0.0 - 9.0.0 + 10.0.10 + 10.0.3 9.0.0 + 10.0.9 7.9.1.24 8.4.1 - 9.0.0 - 9.0.0 + 10.0.0 + 10.0.0 9.0.0.37033 - 9.0.3 + 10.0.2 1.0.1 @@ -90,6 +91,7 @@ + diff --git a/test/NetCorePal.Extensions.DistributedTransactions.CAP.MySql.UnitTests/NetCorePal.Extensions.DistributedTransactions.CAP.MySql.UnitTests.csproj b/test/NetCorePal.Extensions.DistributedTransactions.CAP.MySql.UnitTests/NetCorePal.Extensions.DistributedTransactions.CAP.MySql.UnitTests.csproj index 7dceeb94..503bfd56 100644 --- a/test/NetCorePal.Extensions.DistributedTransactions.CAP.MySql.UnitTests/NetCorePal.Extensions.DistributedTransactions.CAP.MySql.UnitTests.csproj +++ b/test/NetCorePal.Extensions.DistributedTransactions.CAP.MySql.UnitTests/NetCorePal.Extensions.DistributedTransactions.CAP.MySql.UnitTests.csproj @@ -17,7 +17,8 @@ - + + diff --git a/test/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity.UnitTests/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity.UnitTests.csproj b/test/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity.UnitTests/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity.UnitTests.csproj index e562bf4b..564347c5 100644 --- a/test/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity.UnitTests/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity.UnitTests.csproj +++ b/test/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity.UnitTests/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity.UnitTests.csproj @@ -15,7 +15,8 @@ - + + diff --git a/test/NetCorePal.Extensions.Repository.EntityFrameworkCore.UnitTests/NetCorePal.Extensions.Repository.EntityFrameworkCore.UnitTests.csproj b/test/NetCorePal.Extensions.Repository.EntityFrameworkCore.UnitTests/NetCorePal.Extensions.Repository.EntityFrameworkCore.UnitTests.csproj index d907e74f..301d936a 100644 --- a/test/NetCorePal.Extensions.Repository.EntityFrameworkCore.UnitTests/NetCorePal.Extensions.Repository.EntityFrameworkCore.UnitTests.csproj +++ b/test/NetCorePal.Extensions.Repository.EntityFrameworkCore.UnitTests/NetCorePal.Extensions.Repository.EntityFrameworkCore.UnitTests.csproj @@ -15,7 +15,8 @@ - + + diff --git a/test/NetCorePal.Extensions.ShardingCore.UnitTests/NetCorePal.Extensions.ShardingCore.UnitTests.csproj b/test/NetCorePal.Extensions.ShardingCore.UnitTests/NetCorePal.Extensions.ShardingCore.UnitTests.csproj index 0de1e625..863798f0 100644 --- a/test/NetCorePal.Extensions.ShardingCore.UnitTests/NetCorePal.Extensions.ShardingCore.UnitTests.csproj +++ b/test/NetCorePal.Extensions.ShardingCore.UnitTests/NetCorePal.Extensions.ShardingCore.UnitTests.csproj @@ -18,7 +18,8 @@ - + + diff --git a/test/NetCorePal.Extensions.ShardingCore.UnitTests/ShardingMySqlMigrationsSqlGenerator.cs b/test/NetCorePal.Extensions.ShardingCore.UnitTests/ShardingMySqlMigrationsSqlGenerator.cs index 60d8362c..b4d09a74 100644 --- a/test/NetCorePal.Extensions.ShardingCore.UnitTests/ShardingMySqlMigrationsSqlGenerator.cs +++ b/test/NetCorePal.Extensions.ShardingCore.UnitTests/ShardingMySqlMigrationsSqlGenerator.cs @@ -2,8 +2,13 @@ using Microsoft.EntityFrameworkCore.Migrations; using Microsoft.EntityFrameworkCore.Migrations.Operations; using Microsoft.EntityFrameworkCore.Update; +#if NET10_0_OR_GREATER +using Microting.EntityFrameworkCore.MySql.Infrastructure.Internal; +using Microting.EntityFrameworkCore.MySql.Migrations; +#else using Pomelo.EntityFrameworkCore.MySql.Infrastructure.Internal; using Pomelo.EntityFrameworkCore.MySql.Migrations; +#endif using ShardingCore.Core.RuntimeContexts; using ShardingCore.Helpers; diff --git a/test/NetCorePal.Web/NetCorePal.Web.csproj b/test/NetCorePal.Web/NetCorePal.Web.csproj index 406c0f9b..7eea92c3 100644 --- a/test/NetCorePal.Web/NetCorePal.Web.csproj +++ b/test/NetCorePal.Web/NetCorePal.Web.csproj @@ -42,7 +42,8 @@ - + + From 8f0ced0bc42e526d181bc3d70a994edea909262b Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 16 Jul 2026 06:08:09 +0000 Subject: [PATCH 3/8] Clean up: remove PomeloVersion from net10.0 and make PackageVersion conditions symmetric --- Directory.Packages.props | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Directory.Packages.props b/Directory.Packages.props index 274d7bad..d29f0679 100644 --- a/Directory.Packages.props +++ b/Directory.Packages.props @@ -34,7 +34,6 @@ 10.0.0 10.0.10 10.0.3 - 9.0.0 10.0.9 7.9.1.24 8.4.1 @@ -90,7 +89,7 @@ - + From a65b4c68e47954e58992ccf6bb2ca8fc8d4008cb Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 16 Jul 2026 07:35:50 +0000 Subject: [PATCH 4/8] Fix net10.0 CI: upgrade ShardingCore to 7.10.2.1 for EF Core 10 compatibility --- Directory.Packages.props | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Directory.Packages.props b/Directory.Packages.props index d29f0679..76b299a6 100644 --- a/Directory.Packages.props +++ b/Directory.Packages.props @@ -35,7 +35,7 @@ 10.0.10 10.0.3 10.0.9 - 7.9.1.24 + 7.10.2.1 8.4.1 10.0.0 10.0.0 From 12d533cf76c2b363c8ee5c32528d0597737be13d Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 16 Jul 2026 08:43:27 +0000 Subject: [PATCH 5/8] Fix: clear CurrentTransaction before CommitAsync to prevent rollback-after-commit on ShardingCore+Microting net10.0 --- .../AppIdentityDbContextBase.cs | 3 ++- .../AppIdentityUserContextBase.cs | 5 +++-- .../AppDbContextBase.cs | 3 ++- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/src/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity/AppIdentityDbContextBase.cs b/src/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity/AppIdentityDbContextBase.cs index 21a6f6b4..871486f3 100644 --- a/src/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity/AppIdentityDbContextBase.cs +++ b/src/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity/AppIdentityDbContextBase.cs @@ -119,8 +119,9 @@ public async Task CommitAsync(CancellationToken cancellationToken = default) { if (CurrentTransaction != null) { - await CurrentTransaction.CommitAsync(cancellationToken); + var transaction = CurrentTransaction; CurrentTransaction = null; + await transaction.CommitAsync(cancellationToken); } } diff --git a/src/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity/AppIdentityUserContextBase.cs b/src/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity/AppIdentityUserContextBase.cs index 4453faf4..a37f28f9 100644 --- a/src/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity/AppIdentityUserContextBase.cs +++ b/src/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity/AppIdentityUserContextBase.cs @@ -117,9 +117,10 @@ public async Task CommitAsync(CancellationToken cancellationToken = default) { if (CurrentTransaction != null) { - await CurrentTransaction.CommitAsync(cancellationToken); - WriteTransactionCommit(new TransactionCommit(CurrentTransaction.TransactionId)); + var transaction = CurrentTransaction; CurrentTransaction = null; + await transaction.CommitAsync(cancellationToken); + WriteTransactionCommit(new TransactionCommit(transaction.TransactionId)); } } diff --git a/src/NetCorePal.Extensions.Repository.EntityFrameworkCore/AppDbContextBase.cs b/src/NetCorePal.Extensions.Repository.EntityFrameworkCore/AppDbContextBase.cs index 198fdfe7..fdcb5d48 100644 --- a/src/NetCorePal.Extensions.Repository.EntityFrameworkCore/AppDbContextBase.cs +++ b/src/NetCorePal.Extensions.Repository.EntityFrameworkCore/AppDbContextBase.cs @@ -148,8 +148,9 @@ public async Task CommitAsync(CancellationToken cancellationToken = default) { if (CurrentTransaction != null) { - await CurrentTransaction.CommitAsync(cancellationToken); + var transaction = CurrentTransaction; CurrentTransaction = null; + await transaction.CommitAsync(cancellationToken); } } From 7ba9c56c2c60f63ffce4df8eb77c97e132a72eab Mon Sep 17 00:00:00 2001 From: witskeeper Date: Fri, 17 Jul 2026 14:03:58 +0800 Subject: [PATCH 6/8] =?UTF-8?q?=E4=BF=AE=E5=A4=8D:=20=E4=BC=98=E5=8C=96?= =?UTF-8?q?=E4=BA=8B=E5=8A=A1=E6=8F=90=E4=BA=A4=E9=80=BB=E8=BE=91=EF=BC=8C?= =?UTF-8?q?=E7=A7=BB=E9=99=A4=E5=A4=9A=E4=BD=99=E7=9A=84=E4=BA=8B=E5=8A=A1?= =?UTF-8?q?=E5=8F=98=E9=87=8F=E8=B5=8B=E5=80=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../AppIdentityDbContextBase.cs | 3 +-- .../AppIdentityUserContextBase.cs | 5 ++--- .../AppDbContextBase.cs | 3 +-- .../ShardingMySqlMigrationsSqlGenerator.cs | 5 ----- 4 files changed, 4 insertions(+), 12 deletions(-) diff --git a/src/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity/AppIdentityDbContextBase.cs b/src/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity/AppIdentityDbContextBase.cs index 871486f3..21a6f6b4 100644 --- a/src/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity/AppIdentityDbContextBase.cs +++ b/src/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity/AppIdentityDbContextBase.cs @@ -119,9 +119,8 @@ public async Task CommitAsync(CancellationToken cancellationToken = default) { if (CurrentTransaction != null) { - var transaction = CurrentTransaction; + await CurrentTransaction.CommitAsync(cancellationToken); CurrentTransaction = null; - await transaction.CommitAsync(cancellationToken); } } diff --git a/src/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity/AppIdentityUserContextBase.cs b/src/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity/AppIdentityUserContextBase.cs index a37f28f9..4453faf4 100644 --- a/src/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity/AppIdentityUserContextBase.cs +++ b/src/NetCorePal.Extensions.Repository.EntityFrameworkCore.Identity/AppIdentityUserContextBase.cs @@ -117,10 +117,9 @@ public async Task CommitAsync(CancellationToken cancellationToken = default) { if (CurrentTransaction != null) { - var transaction = CurrentTransaction; + await CurrentTransaction.CommitAsync(cancellationToken); + WriteTransactionCommit(new TransactionCommit(CurrentTransaction.TransactionId)); CurrentTransaction = null; - await transaction.CommitAsync(cancellationToken); - WriteTransactionCommit(new TransactionCommit(transaction.TransactionId)); } } diff --git a/src/NetCorePal.Extensions.Repository.EntityFrameworkCore/AppDbContextBase.cs b/src/NetCorePal.Extensions.Repository.EntityFrameworkCore/AppDbContextBase.cs index fdcb5d48..198fdfe7 100644 --- a/src/NetCorePal.Extensions.Repository.EntityFrameworkCore/AppDbContextBase.cs +++ b/src/NetCorePal.Extensions.Repository.EntityFrameworkCore/AppDbContextBase.cs @@ -148,9 +148,8 @@ public async Task CommitAsync(CancellationToken cancellationToken = default) { if (CurrentTransaction != null) { - var transaction = CurrentTransaction; + await CurrentTransaction.CommitAsync(cancellationToken); CurrentTransaction = null; - await transaction.CommitAsync(cancellationToken); } } diff --git a/test/NetCorePal.Extensions.ShardingCore.UnitTests/ShardingMySqlMigrationsSqlGenerator.cs b/test/NetCorePal.Extensions.ShardingCore.UnitTests/ShardingMySqlMigrationsSqlGenerator.cs index b4d09a74..60d8362c 100644 --- a/test/NetCorePal.Extensions.ShardingCore.UnitTests/ShardingMySqlMigrationsSqlGenerator.cs +++ b/test/NetCorePal.Extensions.ShardingCore.UnitTests/ShardingMySqlMigrationsSqlGenerator.cs @@ -2,13 +2,8 @@ using Microsoft.EntityFrameworkCore.Migrations; using Microsoft.EntityFrameworkCore.Migrations.Operations; using Microsoft.EntityFrameworkCore.Update; -#if NET10_0_OR_GREATER -using Microting.EntityFrameworkCore.MySql.Infrastructure.Internal; -using Microting.EntityFrameworkCore.MySql.Migrations; -#else using Pomelo.EntityFrameworkCore.MySql.Infrastructure.Internal; using Pomelo.EntityFrameworkCore.MySql.Migrations; -#endif using ShardingCore.Core.RuntimeContexts; using ShardingCore.Helpers; From e1833fc8b4966de32933b855fbf87d01b38ecf85 Mon Sep 17 00:00:00 2001 From: witskeeper Date: Wed, 29 Jul 2026 11:27:47 +0800 Subject: [PATCH 7/8] =?UTF-8?q?=E4=BF=AE=E5=A4=8D:=20=E6=9B=B4=E6=96=B0=20?= =?UTF-8?q?ShardingCore=20=E7=89=88=E6=9C=AC=E5=B9=B6=E7=A7=BB=E9=99=A4?= =?UTF-8?q?=E4=B8=8D=E5=BF=85=E8=A6=81=E7=9A=84=E6=95=B0=E6=8D=AE=E5=BA=93?= =?UTF-8?q?=E6=8F=90=E4=BE=9B=E8=80=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/test.yml | 2 +- Directory.Packages.props | 6 +++--- .../NetCorePalStorageMockHost.cs | 1 - .../ShardingMySqlMigrationsSqlGenerator.cs | 7 ++++++- 4 files changed, 10 insertions(+), 6 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index f61d923f..5aff4c48 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -33,7 +33,7 @@ jobs: strategy: matrix: framework: [net8.0, net9.0, net10.0] - provider: [DMDB, GaussDB, KingbaseES, MongoDB, MySql, PostgreSql, Sqlite, SqlServer, Base] + provider: [KingbaseES, MongoDB, MySql, PostgreSql, Sqlite, SqlServer, Base] steps: - uses: actions/checkout@v3 - name: Setup .NET diff --git a/Directory.Packages.props b/Directory.Packages.props index 76b299a6..bbe823e8 100644 --- a/Directory.Packages.props +++ b/Directory.Packages.props @@ -9,7 +9,7 @@ 8.0.10 8.0.4 8.0.2 - 7.8.1.24 + 7.8.2.2 8.3.5 8.0.2 8.0.1 @@ -22,7 +22,7 @@ 9.0.0 9.0.1 9.0.0 - 7.9.1.24 + 7.9.2.2 8.4.1 9.0.0 9.0.0 @@ -35,7 +35,7 @@ 10.0.10 10.0.3 10.0.9 - 7.10.2.1 + 7.10.2.2 8.4.1 10.0.0 10.0.0 diff --git a/test/NetCorePal.Extensions.DistributedTransactions.CAP.MongoDB.UnitTests/NetCorePalStorageMockHost.cs b/test/NetCorePal.Extensions.DistributedTransactions.CAP.MongoDB.UnitTests/NetCorePalStorageMockHost.cs index 7289695d..3bba801f 100644 --- a/test/NetCorePal.Extensions.DistributedTransactions.CAP.MongoDB.UnitTests/NetCorePalStorageMockHost.cs +++ b/test/NetCorePal.Extensions.DistributedTransactions.CAP.MongoDB.UnitTests/NetCorePalStorageMockHost.cs @@ -14,7 +14,6 @@ public class NetCorePalStorageMockHost : IAsyncLifetime .WithUsername("guest").WithPassword("guest").Build(); private readonly MongoDbContainer mongoDbContainer = new MongoDbBuilder() - .WithImage("mongo:8.0") .WithReplicaSet("rs0") .WithUsername("admin") .WithPassword("guest") diff --git a/test/NetCorePal.Extensions.ShardingCore.UnitTests/ShardingMySqlMigrationsSqlGenerator.cs b/test/NetCorePal.Extensions.ShardingCore.UnitTests/ShardingMySqlMigrationsSqlGenerator.cs index 60d8362c..50909867 100644 --- a/test/NetCorePal.Extensions.ShardingCore.UnitTests/ShardingMySqlMigrationsSqlGenerator.cs +++ b/test/NetCorePal.Extensions.ShardingCore.UnitTests/ShardingMySqlMigrationsSqlGenerator.cs @@ -2,8 +2,13 @@ using Microsoft.EntityFrameworkCore.Migrations; using Microsoft.EntityFrameworkCore.Migrations.Operations; using Microsoft.EntityFrameworkCore.Update; +#if NET10_0_OR_GREATER +using Microting.EntityFrameworkCore.MySql.Infrastructure.Internal; +using Microting.EntityFrameworkCore.MySql.Migrations; +#else using Pomelo.EntityFrameworkCore.MySql.Infrastructure.Internal; using Pomelo.EntityFrameworkCore.MySql.Migrations; +#endif using ShardingCore.Core.RuntimeContexts; using ShardingCore.Helpers; @@ -31,4 +36,4 @@ protected override void Generate( MigrationHelper.Generate(_shardingRuntimeContext, operation, builder, Dependencies.SqlGenerationHelper, addCmds); } } -} \ No newline at end of file +} From 5777a7fba466ae595c5905081f3f3d45b8d2ded1 Mon Sep 17 00:00:00 2001 From: witskeeper Date: Wed, 29 Jul 2026 11:29:44 +0800 Subject: [PATCH 8/8] =?UTF-8?q?=E6=9B=B4=E6=96=B0:=20=E5=B0=86=E7=89=88?= =?UTF-8?q?=E6=9C=AC=E5=89=8D=E7=BC=80=E4=BB=8E=203.3.0=20=E6=9B=B4?= =?UTF-8?q?=E6=96=B0=E4=B8=BA=203.4.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- eng/versions.props | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eng/versions.props b/eng/versions.props index a12617c7..a246ef5c 100644 --- a/eng/versions.props +++ b/eng/versions.props @@ -1,6 +1,6 @@ - 3.3.0 + 3.4.0