I have successfully converted. Here is the code for anyone who needs it: https://nguyendigital.net/migrating-mongodb-guids-from-legacy-to-standard-format-in-abp
Finally, thank you ABP so much for the help these past 2 days.
I think the best way is from the current database we will create a new one to get the data to be compatible with the structure of mongo v3 but it will be a bit complicated. I wonder if there is a better solution?
It's work. But at the same time it will generate another error when my database already has data.
I still haven't found the optimal way to transfer my old data to be compatible with mongo v3
System.FormatException: 'An error occurred while deserializing the Id property of class Volo.Abp.Domain.Entities.Entity`1[[System.Guid, System.Private.CoreLib, Version=9.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]]: Expected BsonBinarySubType to be UuidStandard, but it is UuidLegacy.'
I tried: https://abp.io/support/questions/9052/Error-Abp-92rc1-Undefined-setting-VoloAbpLeptonXThemeApplicationLayout
And a new error appeared:
using Solann.Software.Localization;
using Volo.Abp.AuditLogging;
using Volo.Abp.BackgroundJobs;
using Volo.Abp.FeatureManagement;
using Volo.Abp.Identity;
using Volo.Abp.Localization;
using Volo.Abp.Localization.ExceptionHandling;
using Volo.Abp.Validation.Localization;
using Volo.Abp.Modularity;
using Volo.Abp.PermissionManagement;
using Volo.Abp.SettingManagement;
using Volo.Abp.VirtualFileSystem;
using Volo.Abp.OpenIddict;
using Volo.Abp.BlobStoring.Database;
using Volo.Abp.LanguageManagement;
using Volo.Saas;
using Volo.Abp.Gdpr;
using Volo.Abp.GlobalFeatures;
namespace Solann.Software;
[DependsOn(
typeof(AbpAuditLoggingDomainSharedModule),
typeof(AbpBackgroundJobsDomainSharedModule),
typeof(AbpFeatureManagementDomainSharedModule),
typeof(AbpPermissionManagementDomainSharedModule),
typeof(AbpSettingManagementDomainSharedModule),
typeof(AbpIdentityProDomainSharedModule),
typeof(AbpOpenIddictProDomainSharedModule),
typeof(LanguageManagementDomainSharedModule),
typeof(SaasDomainSharedModule),
typeof(AbpGdprDomainSharedModule),
typeof(AbpGlobalFeaturesModule),
// typeof(LeptonXThemeManagementDomainShareModule),
typeof(BlobStoringDatabaseDomainSharedModule)
)]
public class SoftwareDomainSharedModule : AbpModule
{
public override void PreConfigureServices(ServiceConfigurationContext context)
{
SoftwareGlobalFeatureConfigurator.Configure();
SoftwareModuleExtensionConfigurator.Configure();
}
public override void ConfigureServices(ServiceConfigurationContext context)
{
Configure<AbpVirtualFileSystemOptions>(options =>
{
options.FileSets.AddEmbedded<SoftwareDomainSharedModule>();
});
Configure<AbpLocalizationOptions>(options =>
{
options.Resources
.Add<SoftwareResource>("vi")
.AddBaseTypes(typeof(AbpValidationResource))
.AddVirtualJson("/Localization/Software");
options.DefaultResourceType = typeof(SoftwareResource);
});
Configure<AbpExceptionLocalizationOptions>(options =>
{
options.MapCodeNamespace("Software", typeof(SoftwareResource));
});
}
}
and Solann.Software.Domain.Shared
<Project Sdk="Microsoft.NET.Sdk">
<Import Project="....\common.props" />
<PropertyGroup> <TargetFramework>net9.0</TargetFramework> <Nullable>enable</Nullable> <RootNamespace>Solann.Software</RootNamespace> <GenerateEmbeddedFilesManifest>true</GenerateEmbeddedFilesManifest> </PropertyGroup>
<ItemGroup> <PackageReference Include="Volo.Abp.BackgroundJobs.Domain.Shared" Version="9.2.0-rc.1" /> <PackageReference Include="Volo.Abp.AuditLogging.Domain.Shared" Version="9.2.0-rc.1" /> <PackageReference Include="Volo.Abp.FeatureManagement.Domain.Shared" Version="9.2.0-rc.1" /> <PackageReference Include="Volo.Abp.PermissionManagement.Domain.Shared" Version="9.2.0-rc.1" /> <PackageReference Include="Volo.Abp.SettingManagement.Domain.Shared" Version="9.2.0-rc.1" /> <PackageReference Include="Volo.Abp.BlobStoring.Database.Domain.Shared" Version="9.2.0-rc.1" /> <PackageReference Include="Volo.Abp.GlobalFeatures" Version="9.2.0-rc.1" /> </ItemGroup>
<ItemGroup> <PackageReference Include="Volo.Abp.OpenIddict.Pro.Domain.Shared" Version="9.2.0-rc.1" /> <PackageReference Include="Volo.Abp.Identity.Pro.Domain.Shared" Version="9.2.0-rc.1" /> <PackageReference Include="Volo.Abp.LanguageManagement.Domain.Shared" Version="9.2.0-rc.1" /> <PackageReference Include="Volo.Saas.Domain.Shared" Version="9.2.0-rc.1" /> <PackageReference Include="Volo.Abp.Gdpr.Domain.Shared" Version="9.2.0-rc.1" /> </ItemGroup>
<ItemGroup> <PackageReference Include="Microsoft.Extensions.FileProviders.Embedded" Version="9.0.3" /> </ItemGroup>
<ItemGroup> <EmbeddedResource Include="Localization\Software*.json" /> <Content Remove="Localization\Software*.json" /> </ItemGroup>
</Project>
Error (active) NU1101 Unable to find package Volo.Abp.LeptonXTheme.Management.Domain.Shared. No packages exist with this id in source(s): nuget.abp.io, nuget.org. PackageSourceMapping is enabled, the following source(s) were not considered: C:\Program Files\dotnet\library-packs, Microsoft Visual Studio Offline Packages. Solann.Software.Web I:\SolannSoftware\Solann.Software\src\Solann.Software.Web\Solann.Software.Web.csproj
Please check for me.
Thank you. It's work