diff --git a/aspnet-core/LINGYUN.MicroService.All.sln b/aspnet-core/LINGYUN.MicroService.All.sln index 1be7d20b1..ebefea6f9 100644 --- a/aspnet-core/LINGYUN.MicroService.All.sln +++ b/aspnet-core/LINGYUN.MicroService.All.sln @@ -547,7 +547,7 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "LINGYUN.Abp.Notifications.A EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "LINGYUN.Abp.Notifications.HttpApi", "modules\notifications\LINGYUN.Abp.Notifications.HttpApi\LINGYUN.Abp.Notifications.HttpApi.csproj", "{EFC5C34F-81A1-4EFC-966F-50B646C54FA6}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "LINGYUN.Abp.Localization.Persistence", "modules\localization\LINGYUN.Abp.Localization.Persistence\LINGYUN.Abp.Localization.Persistence.csproj", "{42A0FC3F-C38E-4FF4-B78A-5ED29DF144BF}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "LINGYUN.Abp.Localization.Persistence", "modules\localization\LINGYUN.Abp.Localization.Persistence\LINGYUN.Abp.Localization.Persistence.csproj", "{42A0FC3F-C38E-4FF4-B78A-5ED29DF144BF}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution diff --git a/aspnet-core/modules/common/LINGYUN.Abp.AspNetCore.Mvc.Client/Properties/launchSettings.json b/aspnet-core/modules/common/LINGYUN.Abp.AspNetCore.Mvc.Client/Properties/launchSettings.json deleted file mode 100644 index 7cd042c63..000000000 --- a/aspnet-core/modules/common/LINGYUN.Abp.AspNetCore.Mvc.Client/Properties/launchSettings.json +++ /dev/null @@ -1,27 +0,0 @@ -{ - "iisSettings": { - "windowsAuthentication": false, - "anonymousAuthentication": true, - "iisExpress": { - "applicationUrl": "http://localhost:41514/", - "sslPort": 44331 - } - }, - "profiles": { - "IIS Express": { - "commandName": "IISExpress", - "launchBrowser": true, - "environmentVariables": { - "ASPNETCORE_ENVIRONMENT": "Development" - } - }, - "LINGYUN.Abp.AspNetCore.Mvc.Client": { - "commandName": "Project", - "launchBrowser": true, - "environmentVariables": { - "ASPNETCORE_ENVIRONMENT": "Development" - }, - "applicationUrl": "https://localhost:5001;http://localhost:5000" - } - } -} \ No newline at end of file diff --git a/aspnet-core/modules/notifications/LINGYUN.Abp.Notifications.Domain/LINGYUN/Abp/Notifications/AbpNotificationsManagementOptions.cs b/aspnet-core/modules/notifications/LINGYUN.Abp.Notifications.Domain/LINGYUN/Abp/Notifications/AbpNotificationsManagementOptions.cs index 70ddb801d..b0f0d828d 100644 --- a/aspnet-core/modules/notifications/LINGYUN.Abp.Notifications.Domain/LINGYUN/Abp/Notifications/AbpNotificationsManagementOptions.cs +++ b/aspnet-core/modules/notifications/LINGYUN.Abp.Notifications.Domain/LINGYUN/Abp/Notifications/AbpNotificationsManagementOptions.cs @@ -4,7 +4,13 @@ namespace LINGYUN.Abp.Notifications; public class AbpNotificationsManagementOptions { + /// + /// Default: true. + /// public bool SaveStaticNotificationsToDatabase { get; set; } + /// + /// Default: false. + /// public bool IsDynamicNotificationsStoreEnabled { get; set; } /// /// 缓存刷新时间 @@ -24,7 +30,6 @@ public class AbpNotificationsManagementOptions public AbpNotificationsManagementOptions() { SaveStaticNotificationsToDatabase = true; - IsDynamicNotificationsStoreEnabled = true; NotificationsCacheRefreshInterval = TimeSpan.FromSeconds(30); NotificationsCacheStampTimeOut = TimeSpan.FromMinutes(2); diff --git a/aspnet-core/modules/oss-management/LINGYUN.Abp.OssManagement.Tencent/Properties/launchSettings.json b/aspnet-core/modules/oss-management/LINGYUN.Abp.OssManagement.Tencent/Properties/launchSettings.json deleted file mode 100644 index 5cb98d623..000000000 --- a/aspnet-core/modules/oss-management/LINGYUN.Abp.OssManagement.Tencent/Properties/launchSettings.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "profiles": { - "LINGYUN.Abp.OssManagement.Tencent": { - "commandName": "Project", - "launchBrowser": true, - "environmentVariables": { - "ASPNETCORE_ENVIRONMENT": "Development" - }, - "applicationUrl": "https://localhost:58740;http://localhost:58741" - } - } -} \ No newline at end of file diff --git a/aspnet-core/modules/tenants/LINGYUN.Abp.MultiTenancy.Saas/Properties/launchSettings.json b/aspnet-core/modules/tenants/LINGYUN.Abp.MultiTenancy.Saas/Properties/launchSettings.json deleted file mode 100644 index 9959c3f46..000000000 --- a/aspnet-core/modules/tenants/LINGYUN.Abp.MultiTenancy.Saas/Properties/launchSettings.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "profiles": { - "LINGYUN.Abp.MultiTenancy.Saas": { - "commandName": "Project", - "launchBrowser": true, - "environmentVariables": { - "ASPNETCORE_ENVIRONMENT": "Development" - }, - "applicationUrl": "https://localhost:58776;http://localhost:58777" - } - } -} \ No newline at end of file diff --git a/aspnet-core/modules/webhooks/LINGYUN.Abp.WebhooksManagement.Domain/LINGYUN/Abp/WebhooksManagement/DynamicWebhookDefinitionStore.cs b/aspnet-core/modules/webhooks/LINGYUN.Abp.WebhooksManagement.Domain/LINGYUN/Abp/WebhooksManagement/DynamicWebhookDefinitionStore.cs index 126c720c7..2ae65ead3 100644 --- a/aspnet-core/modules/webhooks/LINGYUN.Abp.WebhooksManagement.Domain/LINGYUN/Abp/WebhooksManagement/DynamicWebhookDefinitionStore.cs +++ b/aspnet-core/modules/webhooks/LINGYUN.Abp.WebhooksManagement.Domain/LINGYUN/Abp/WebhooksManagement/DynamicWebhookDefinitionStore.cs @@ -22,7 +22,7 @@ public class DynamicWebhookDefinitionStore : IDynamicWebhookDefinitionStore, ITr protected IDynamicWebhookDefinitionStoreCache StoreCache { get; } protected IDistributedCache DistributedCache { get; } protected IAbpDistributedLock DistributedLock { get; } - protected WebhookManagementOptions WebhookManagementOptions { get; } + protected WebhooksManagementOptions WebhookManagementOptions { get; } protected AbpDistributedCacheOptions CacheOptions { get; } public DynamicWebhookDefinitionStore( @@ -32,7 +32,7 @@ public class DynamicWebhookDefinitionStore : IDynamicWebhookDefinitionStore, ITr IDynamicWebhookDefinitionStoreCache storeCache, IDistributedCache distributedCache, IOptions cacheOptions, - IOptions webhookManagementOptions, + IOptions webhookManagementOptions, IAbpDistributedLock distributedLock) { WebhookGroupRepository = webhookGroupRepository; diff --git a/aspnet-core/modules/webhooks/LINGYUN.Abp.WebhooksManagement.Domain/LINGYUN/Abp/WebhooksManagement/WebhooksManagementDomainModule.cs b/aspnet-core/modules/webhooks/LINGYUN.Abp.WebhooksManagement.Domain/LINGYUN/Abp/WebhooksManagement/WebhooksManagementDomainModule.cs index 9b1c7f446..1ed8d8d40 100644 --- a/aspnet-core/modules/webhooks/LINGYUN.Abp.WebhooksManagement.Domain/LINGYUN/Abp/WebhooksManagement/WebhooksManagementDomainModule.cs +++ b/aspnet-core/modules/webhooks/LINGYUN.Abp.WebhooksManagement.Domain/LINGYUN/Abp/WebhooksManagement/WebhooksManagementDomainModule.cs @@ -49,7 +49,7 @@ public class WebhooksManagementDomainModule : AbpModule if (context.Services.IsDataMigrationEnvironment()) { - Configure(options => + Configure(options => { options.SaveStaticWebhooksToDatabase = false; options.IsDynamicWebhookStoreEnabled = false; @@ -111,7 +111,7 @@ public class WebhooksManagementDomainModule : AbpModule { var options = context .ServiceProvider - .GetRequiredService>() + .GetRequiredService>() .Value; if (!options.SaveStaticWebhooksToDatabase && !options.IsDynamicWebhookStoreEnabled) @@ -153,7 +153,7 @@ public class WebhooksManagementDomainModule : AbpModule } private async static Task SaveStaticWebhooksToDatabaseAsync( - WebhookManagementOptions options, + WebhooksManagementOptions options, IServiceScope scope, ICancellationTokenProvider cancellationTokenProvider) { @@ -187,7 +187,7 @@ public class WebhooksManagementDomainModule : AbpModule }, cancellationTokenProvider.Token); } - private async static Task PreCacheDynamicWebhooksAsync(WebhookManagementOptions options, IServiceScope scope) + private async static Task PreCacheDynamicWebhooksAsync(WebhooksManagementOptions options, IServiceScope scope) { if (!options.IsDynamicWebhookStoreEnabled) { diff --git a/aspnet-core/modules/webhooks/LINGYUN.Abp.WebhooksManagement.Domain/LINGYUN/Abp/WebhooksManagement/WebhookManagementOptions.cs b/aspnet-core/modules/webhooks/LINGYUN.Abp.WebhooksManagement.Domain/LINGYUN/Abp/WebhooksManagement/WebhooksManagementOptions.cs similarity index 86% rename from aspnet-core/modules/webhooks/LINGYUN.Abp.WebhooksManagement.Domain/LINGYUN/Abp/WebhooksManagement/WebhookManagementOptions.cs rename to aspnet-core/modules/webhooks/LINGYUN.Abp.WebhooksManagement.Domain/LINGYUN/Abp/WebhooksManagement/WebhooksManagementOptions.cs index 1cdac2185..3f77f6ffc 100644 --- a/aspnet-core/modules/webhooks/LINGYUN.Abp.WebhooksManagement.Domain/LINGYUN/Abp/WebhooksManagement/WebhookManagementOptions.cs +++ b/aspnet-core/modules/webhooks/LINGYUN.Abp.WebhooksManagement.Domain/LINGYUN/Abp/WebhooksManagement/WebhooksManagementOptions.cs @@ -1,7 +1,7 @@ using System; namespace LINGYUN.Abp.WebhooksManagement; -public class WebhookManagementOptions +public class WebhooksManagementOptions { /// /// Default: true. @@ -26,9 +26,8 @@ public class WebhookManagementOptions /// default: 30 minutes /// public TimeSpan WebhooksCacheStampExpiration { get; set; } - public WebhookManagementOptions() + public WebhooksManagementOptions() { - IsDynamicWebhookStoreEnabled = true; SaveStaticWebhooksToDatabase = true; WebhooksCacheRefreshInterval = TimeSpan.FromSeconds(30); diff --git a/aspnet-core/services/LY.MicroService.AuthServer.HttpApi.Host/AuthServerHttpApiHostModule.Configure.cs b/aspnet-core/services/LY.MicroService.AuthServer.HttpApi.Host/AuthServerHttpApiHostModule.Configure.cs index a9bf5ca33..68d7528c7 100644 --- a/aspnet-core/services/LY.MicroService.AuthServer.HttpApi.Host/AuthServerHttpApiHostModule.Configure.cs +++ b/aspnet-core/services/LY.MicroService.AuthServer.HttpApi.Host/AuthServerHttpApiHostModule.Configure.cs @@ -24,6 +24,7 @@ using Volo.Abp.Authorization.Permissions; using Volo.Abp.Caching; using Volo.Abp.Domain.Entities.Events.Distributed; using Volo.Abp.EntityFrameworkCore; +using Volo.Abp.FeatureManagement; using Volo.Abp.GlobalFeatures; using Volo.Abp.Json; using Volo.Abp.Json.SystemTextJson; @@ -112,6 +113,14 @@ public partial class AuthServerHttpApiHostModule }); } + private void ConfigureFeatureManagement() + { + Configure(options => + { + options.IsDynamicFeatureStoreEnabled = true; + }); + } + private void ConfigurePermissionManagement() { Configure(options => diff --git a/aspnet-core/services/LY.MicroService.AuthServer.HttpApi.Host/AuthServerHttpApiHostModule.cs b/aspnet-core/services/LY.MicroService.AuthServer.HttpApi.Host/AuthServerHttpApiHostModule.cs index fadd89a68..6fd04ba1a 100644 --- a/aspnet-core/services/LY.MicroService.AuthServer.HttpApi.Host/AuthServerHttpApiHostModule.cs +++ b/aspnet-core/services/LY.MicroService.AuthServer.HttpApi.Host/AuthServerHttpApiHostModule.cs @@ -24,6 +24,7 @@ using Volo.Abp.AspNetCore.Serilog; using Volo.Abp.Autofac; using Volo.Abp.Caching.StackExchangeRedis; using Volo.Abp.EntityFrameworkCore.MySQL; +using Volo.Abp.FeatureManagement.EntityFrameworkCore; using Volo.Abp.Modularity; using Volo.Abp.OpenIddict.EntityFrameworkCore; using Volo.Abp.PermissionManagement.EntityFrameworkCore; @@ -47,6 +48,7 @@ namespace LY.MicroService.AuthServer; typeof(AbpOpenIddictEntityFrameworkCoreModule), typeof(AbpEntityFrameworkCoreMySQLModule), typeof(AbpSaasEntityFrameworkCoreModule), + typeof(AbpFeatureManagementEntityFrameworkCoreModule), typeof(AbpSettingManagementEntityFrameworkCoreModule), typeof(AbpPermissionManagementEntityFrameworkCoreModule), typeof(AbpLocalizationManagementEntityFrameworkCoreModule), @@ -82,6 +84,7 @@ public partial class AuthServerHttpApiHostModule : AbpModule ConfigureJsonSerializer(); ConfigreExceptionHandling(); ConfigureVirtualFileSystem(); + ConfigureFeatureManagement(); ConfigurePermissionManagement(); ConfigureUrls(configuration); ConfigureCaching(configuration); diff --git a/aspnet-core/services/LY.MicroService.AuthServer.HttpApi.Host/LY.MicroService.AuthServer.HttpApi.Host.csproj b/aspnet-core/services/LY.MicroService.AuthServer.HttpApi.Host/LY.MicroService.AuthServer.HttpApi.Host.csproj index f739271bd..66c71169f 100644 --- a/aspnet-core/services/LY.MicroService.AuthServer.HttpApi.Host/LY.MicroService.AuthServer.HttpApi.Host.csproj +++ b/aspnet-core/services/LY.MicroService.AuthServer.HttpApi.Host/LY.MicroService.AuthServer.HttpApi.Host.csproj @@ -31,6 +31,7 @@ + diff --git a/aspnet-core/services/LY.MicroService.AuthServer/AuthServerModule.Configure.cs b/aspnet-core/services/LY.MicroService.AuthServer/AuthServerModule.Configure.cs index 10bdbacdf..85d2e807c 100644 --- a/aspnet-core/services/LY.MicroService.AuthServer/AuthServerModule.Configure.cs +++ b/aspnet-core/services/LY.MicroService.AuthServer/AuthServerModule.Configure.cs @@ -24,6 +24,7 @@ using Volo.Abp.Account.Localization; using Volo.Abp.Auditing; using Volo.Abp.Caching; using Volo.Abp.EntityFrameworkCore; +using Volo.Abp.FeatureManagement; using Volo.Abp.GlobalFeatures; using Volo.Abp.Json; using Volo.Abp.Json.SystemTextJson; @@ -172,6 +173,14 @@ public partial class AuthServerModule } + private void ConfigureFeatureManagement() + { + Configure(options => + { + options.IsDynamicFeatureStoreEnabled = true; + }); + } + private void ConfigureJsonSerializer() { // 统一时间日期格式 diff --git a/aspnet-core/services/LY.MicroService.AuthServer/AuthServerModule.cs b/aspnet-core/services/LY.MicroService.AuthServer/AuthServerModule.cs index ab8e6ba32..4753ceeab 100644 --- a/aspnet-core/services/LY.MicroService.AuthServer/AuthServerModule.cs +++ b/aspnet-core/services/LY.MicroService.AuthServer/AuthServerModule.cs @@ -97,6 +97,7 @@ public partial class AuthServerModule : AbpModule ConfigureCaching(configuration); ConfigureIdentity(configuration); ConfigureVirtualFileSystem(); + ConfigureFeatureManagement(); ConfigureLocalization(); ConfigureDataSeeder(); ConfigureUrls(configuration); diff --git a/aspnet-core/services/LY.MicroService.BackendAdmin.HttpApi.Host/BackendAdminHttpApiHostModule.Configure.cs b/aspnet-core/services/LY.MicroService.BackendAdmin.HttpApi.Host/BackendAdminHttpApiHostModule.Configure.cs index ef9943f4d..6211c845e 100644 --- a/aspnet-core/services/LY.MicroService.BackendAdmin.HttpApi.Host/BackendAdminHttpApiHostModule.Configure.cs +++ b/aspnet-core/services/LY.MicroService.BackendAdmin.HttpApi.Host/BackendAdminHttpApiHostModule.Configure.cs @@ -96,6 +96,8 @@ public partial class BackendAdminHttpApiHostModule { options.ProviderPolicies[EditionFeatureValueProvider.ProviderName] = AbpSaasPermissions.Editions.ManageFeatures; options.ProviderPolicies[TenantFeatureValueProvider.ProviderName] = AbpSaasPermissions.Tenants.ManageFeatures; + + options.IsDynamicFeatureStoreEnabled = true; }); } diff --git a/aspnet-core/services/LY.MicroService.LocalizationManagement.HttpApi.Host/LY.MicroService.LocalizationManagement.HttpApi.Host.csproj b/aspnet-core/services/LY.MicroService.LocalizationManagement.HttpApi.Host/LY.MicroService.LocalizationManagement.HttpApi.Host.csproj index 943087712..30e3b0329 100644 --- a/aspnet-core/services/LY.MicroService.LocalizationManagement.HttpApi.Host/LY.MicroService.LocalizationManagement.HttpApi.Host.csproj +++ b/aspnet-core/services/LY.MicroService.LocalizationManagement.HttpApi.Host/LY.MicroService.LocalizationManagement.HttpApi.Host.csproj @@ -26,6 +26,7 @@ + diff --git a/aspnet-core/services/LY.MicroService.LocalizationManagement.HttpApi.Host/LocalizationManagementHttpApiHostModule.Configure.cs b/aspnet-core/services/LY.MicroService.LocalizationManagement.HttpApi.Host/LocalizationManagementHttpApiHostModule.Configure.cs index 9a68a4698..fd4f31285 100644 --- a/aspnet-core/services/LY.MicroService.LocalizationManagement.HttpApi.Host/LocalizationManagementHttpApiHostModule.Configure.cs +++ b/aspnet-core/services/LY.MicroService.LocalizationManagement.HttpApi.Host/LocalizationManagementHttpApiHostModule.Configure.cs @@ -20,6 +20,7 @@ using Volo.Abp; using Volo.Abp.Auditing; using Volo.Abp.Caching; using Volo.Abp.EntityFrameworkCore; +using Volo.Abp.FeatureManagement; using Volo.Abp.GlobalFeatures; using Volo.Abp.Json; using Volo.Abp.Json.SystemTextJson; @@ -84,6 +85,14 @@ public partial class LocalizationManagementHttpApiHostModule }); } + private void ConfigureFeatureManagement() + { + Configure(options => + { + options.IsDynamicFeatureStoreEnabled = true; + }); + } + private void ConfigureJsonSerializer() { // 统一时间日期格式 diff --git a/aspnet-core/services/LY.MicroService.LocalizationManagement.HttpApi.Host/LocalizationManagementHttpApiHostModule.cs b/aspnet-core/services/LY.MicroService.LocalizationManagement.HttpApi.Host/LocalizationManagementHttpApiHostModule.cs index c58e879bb..7f37984bc 100644 --- a/aspnet-core/services/LY.MicroService.LocalizationManagement.HttpApi.Host/LocalizationManagementHttpApiHostModule.cs +++ b/aspnet-core/services/LY.MicroService.LocalizationManagement.HttpApi.Host/LocalizationManagementHttpApiHostModule.cs @@ -23,6 +23,7 @@ using Volo.Abp.AspNetCore.Serilog; using Volo.Abp.Autofac; using Volo.Abp.Caching.StackExchangeRedis; using Volo.Abp.EntityFrameworkCore.MySQL; +using Volo.Abp.FeatureManagement.EntityFrameworkCore; using Volo.Abp.Modularity; using Volo.Abp.PermissionManagement.EntityFrameworkCore; using Volo.Abp.SettingManagement.EntityFrameworkCore; @@ -40,6 +41,7 @@ namespace LY.MicroService.LocalizationManagement typeof(AbpLocalizationManagementEntityFrameworkCoreModule), typeof(AbpEntityFrameworkCoreMySQLModule), typeof(AbpSaasEntityFrameworkCoreModule), + typeof(AbpFeatureManagementEntityFrameworkCoreModule), typeof(AbpSettingManagementEntityFrameworkCoreModule), typeof(AbpPermissionManagementEntityFrameworkCoreModule), typeof(AbpDataDbMigratorModule), @@ -75,6 +77,7 @@ namespace LY.MicroService.LocalizationManagement ConfigureJsonSerializer(); ConfigreExceptionHandling(); ConfigureVirtualFileSystem(); + ConfigureFeatureManagement(); ConfigureCaching(configuration); ConfigureAuditing(configuration); ConfigureSwagger(context.Services); diff --git a/aspnet-core/services/LY.MicroService.PlatformManagement.HttpApi.Host/PlatformManagementHttpApiHostModule.Configure.cs b/aspnet-core/services/LY.MicroService.PlatformManagement.HttpApi.Host/PlatformManagementHttpApiHostModule.Configure.cs index ce2ef05f6..537f7a854 100644 --- a/aspnet-core/services/LY.MicroService.PlatformManagement.HttpApi.Host/PlatformManagementHttpApiHostModule.Configure.cs +++ b/aspnet-core/services/LY.MicroService.PlatformManagement.HttpApi.Host/PlatformManagementHttpApiHostModule.Configure.cs @@ -25,6 +25,7 @@ using Volo.Abp.BlobStoring; using Volo.Abp.BlobStoring.FileSystem; using Volo.Abp.Caching; using Volo.Abp.EntityFrameworkCore; +using Volo.Abp.FeatureManagement; using Volo.Abp.GlobalFeatures; using Volo.Abp.Json; using Volo.Abp.Json.SystemTextJson; @@ -88,6 +89,14 @@ public partial class PlatformManagementHttpApiHostModule }); } + private void ConfigureFeatureManagement() + { + Configure(options => + { + options.IsDynamicFeatureStoreEnabled = true; + }); + } + private void ConfigureJsonSerializer() { // 统一时间日期格式 diff --git a/aspnet-core/services/LY.MicroService.PlatformManagement.HttpApi.Host/PlatformManagementHttpApiHostModule.cs b/aspnet-core/services/LY.MicroService.PlatformManagement.HttpApi.Host/PlatformManagementHttpApiHostModule.cs index a4ecd9b1d..f7dbb4567 100644 --- a/aspnet-core/services/LY.MicroService.PlatformManagement.HttpApi.Host/PlatformManagementHttpApiHostModule.cs +++ b/aspnet-core/services/LY.MicroService.PlatformManagement.HttpApi.Host/PlatformManagementHttpApiHostModule.cs @@ -109,6 +109,7 @@ public partial class PlatformManagementHttpApiHostModule : AbpModule ConfigureJsonSerializer(); ConfigreExceptionHandling(); ConfigureVirtualFileSystem(); + ConfigureFeatureManagement(); ConfigureCaching(configuration); ConfigureAuditing(configuration); ConfigureSwagger(context.Services); diff --git a/aspnet-core/services/LY.MicroService.RealtimeMessage.HttpApi.Host/RealtimeMessageHttpApiHostModule.Configure.cs b/aspnet-core/services/LY.MicroService.RealtimeMessage.HttpApi.Host/RealtimeMessageHttpApiHostModule.Configure.cs index f7cdfd09d..ce63cc9c7 100644 --- a/aspnet-core/services/LY.MicroService.RealtimeMessage.HttpApi.Host/RealtimeMessageHttpApiHostModule.Configure.cs +++ b/aspnet-core/services/LY.MicroService.RealtimeMessage.HttpApi.Host/RealtimeMessageHttpApiHostModule.Configure.cs @@ -3,6 +3,7 @@ using LINGYUN.Abp.BackgroundTasks; using LINGYUN.Abp.ExceptionHandling; using LINGYUN.Abp.Localization.CultureMap; using LINGYUN.Abp.MessageService.Localization; +using LINGYUN.Abp.Notifications; using LINGYUN.Abp.Serilog.Enrichers.Application; using LINGYUN.Abp.Serilog.Enrichers.UniqueId; using LY.MicroService.RealtimeMessage.BackgroundJobs; @@ -26,6 +27,7 @@ using Volo.Abp; using Volo.Abp.Auditing; using Volo.Abp.Caching; using Volo.Abp.EntityFrameworkCore; +using Volo.Abp.FeatureManagement; using Volo.Abp.GlobalFeatures; using Volo.Abp.Json; using Volo.Abp.Json.SystemTextJson; @@ -126,6 +128,14 @@ public partial class RealtimeMessageHttpApiHostModule }); } + private void ConfigureFeatureManagement() + { + Configure(options => + { + options.IsDynamicFeatureStoreEnabled = true; + }); + } + private void ConfigureJsonSerializer() { // 统一时间日期格式 @@ -217,6 +227,15 @@ public partial class RealtimeMessageHttpApiHostModule }); } + private void ConfigureNotifications() + { + Configure(options => + { + // 宿主项目启用动态通知 + options.IsDynamicNotificationsStoreEnabled = true; + }); + } + private void ConfigureMultiTenancy(IConfiguration configuration) { // 多租户 diff --git a/aspnet-core/services/LY.MicroService.RealtimeMessage.HttpApi.Host/RealtimeMessageHttpApiHostModule.cs b/aspnet-core/services/LY.MicroService.RealtimeMessage.HttpApi.Host/RealtimeMessageHttpApiHostModule.cs index c5181b437..0b538013b 100644 --- a/aspnet-core/services/LY.MicroService.RealtimeMessage.HttpApi.Host/RealtimeMessageHttpApiHostModule.cs +++ b/aspnet-core/services/LY.MicroService.RealtimeMessage.HttpApi.Host/RealtimeMessageHttpApiHostModule.cs @@ -121,10 +121,12 @@ public partial class RealtimeMessageHttpApiHostModule : AbpModule ConfigureDbContext(); ConfigureLocalization(); + ConfigureNotifications(); ConfigureJsonSerializer(); ConfigureBackgroundTasks(); ConfigreExceptionHandling(); ConfigureVirtualFileSystem(); + ConfigureFeatureManagement(); ConfigureCaching(configuration); ConfigureAuditing(configuration); ConfigureSwagger(context.Services); diff --git a/aspnet-core/services/LY.MicroService.TaskManagement.HttpApi.Host/TaskManagementHttpApiHostModule.Configure.cs b/aspnet-core/services/LY.MicroService.TaskManagement.HttpApi.Host/TaskManagementHttpApiHostModule.Configure.cs index f60b924ec..c541b3f63 100644 --- a/aspnet-core/services/LY.MicroService.TaskManagement.HttpApi.Host/TaskManagementHttpApiHostModule.Configure.cs +++ b/aspnet-core/services/LY.MicroService.TaskManagement.HttpApi.Host/TaskManagementHttpApiHostModule.Configure.cs @@ -23,6 +23,7 @@ using Volo.Abp; using Volo.Abp.Auditing; using Volo.Abp.Caching; using Volo.Abp.EntityFrameworkCore; +using Volo.Abp.FeatureManagement; using Volo.Abp.GlobalFeatures; using Volo.Abp.Json; using Volo.Abp.Json.SystemTextJson; @@ -114,6 +115,14 @@ public partial class TaskManagementHttpApiHostModule }); } + private void ConfigureFeatureManagement() + { + Configure(options => + { + options.IsDynamicFeatureStoreEnabled = true; + }); + } + private void ConfigureDistributedLock(IServiceCollection services, IConfiguration configuration) { var redis = ConnectionMultiplexer.Connect(configuration["DistributedLock:Redis:Configuration"]); diff --git a/aspnet-core/services/LY.MicroService.TaskManagement.HttpApi.Host/TaskManagementHttpApiHostModule.cs b/aspnet-core/services/LY.MicroService.TaskManagement.HttpApi.Host/TaskManagementHttpApiHostModule.cs index b69663ef5..e6d7eaa3b 100644 --- a/aspnet-core/services/LY.MicroService.TaskManagement.HttpApi.Host/TaskManagementHttpApiHostModule.cs +++ b/aspnet-core/services/LY.MicroService.TaskManagement.HttpApi.Host/TaskManagementHttpApiHostModule.cs @@ -100,6 +100,7 @@ public partial class TaskManagementHttpApiHostModule : AbpModule ConfigureBackgroundTasks(); ConfigureExceptionHandling(); ConfigureVirtualFileSystem(); + ConfigureFeatureManagement(); ConfigureCaching(configuration); ConfigureAuditing(configuration); ConfigureMultiTenancy(configuration); diff --git a/aspnet-core/services/LY.MicroService.WebhooksManagement.HttpApi.Host/WebhooksManagementHttpApiHostModule.Configure.cs b/aspnet-core/services/LY.MicroService.WebhooksManagement.HttpApi.Host/WebhooksManagementHttpApiHostModule.Configure.cs index b278692fa..1871e9ea9 100644 --- a/aspnet-core/services/LY.MicroService.WebhooksManagement.HttpApi.Host/WebhooksManagementHttpApiHostModule.Configure.cs +++ b/aspnet-core/services/LY.MicroService.WebhooksManagement.HttpApi.Host/WebhooksManagementHttpApiHostModule.Configure.cs @@ -4,6 +4,8 @@ using LINGYUN.Abp.ExceptionHandling; using LINGYUN.Abp.ExceptionHandling.Emailing; using LINGYUN.Abp.Serilog.Enrichers.Application; using LINGYUN.Abp.Serilog.Enrichers.UniqueId; +using LINGYUN.Abp.Webhooks; +using LINGYUN.Abp.WebhooksManagement; using LINGYUN.Abp.Wrapper; using Medallion.Threading; using Medallion.Threading.Redis; @@ -12,6 +14,7 @@ using Microsoft.AspNetCore.DataProtection; using Microsoft.Extensions.Caching.StackExchangeRedis; using Microsoft.Extensions.Configuration; using Microsoft.Extensions.DependencyInjection; +using Microsoft.Extensions.DependencyInjection.Extensions; using Microsoft.OpenApi.Models; using OpenTelemetry.Resources; using OpenTelemetry.Trace; @@ -25,6 +28,7 @@ using Volo.Abp; using Volo.Abp.Auditing; using Volo.Abp.Caching; using Volo.Abp.EntityFrameworkCore; +using Volo.Abp.FeatureManagement; using Volo.Abp.GlobalFeatures; using Volo.Abp.Json; using Volo.Abp.Json.SystemTextJson; @@ -294,6 +298,26 @@ public partial class WebhooksManagementHttpApiHostModule }); } + private void ConfigureFeatureManagement() + { + Configure(options => + { + options.IsDynamicFeatureStoreEnabled = true; + }); + } + + private void ConfigureWebhooks(IServiceCollection services) + { + Configure(options => + { + // 宿主应用中启用动态webhook + options.IsDynamicWebhookStoreEnabled = true; + }); + + // 宿主应用中使用默认发布者 + services.Replace(ServiceDescriptor.Transient()); + } + private void ConfigureLocalization() { // 支持本地化语言类型 diff --git a/aspnet-core/services/LY.MicroService.WebhooksManagement.HttpApi.Host/WebhooksManagementHttpApiHostModule.cs b/aspnet-core/services/LY.MicroService.WebhooksManagement.HttpApi.Host/WebhooksManagementHttpApiHostModule.cs index 6fd69c944..05c6ad7a8 100644 --- a/aspnet-core/services/LY.MicroService.WebhooksManagement.HttpApi.Host/WebhooksManagementHttpApiHostModule.cs +++ b/aspnet-core/services/LY.MicroService.WebhooksManagement.HttpApi.Host/WebhooksManagementHttpApiHostModule.cs @@ -1,18 +1,20 @@ -using DotNetCore.CAP; -using LINGYUN.Abp.AspNetCore.Mvc.Localization; +using LINGYUN.Abp.AspNetCore.Mvc.Localization; using LINGYUN.Abp.AspNetCore.Mvc.Wrapper; using LINGYUN.Abp.AuditLogging.Elasticsearch; using LINGYUN.Abp.Authorization.OrganizationUnits; -using LINGYUN.Abp.BackgroundTasks.ExceptionHandling; using LINGYUN.Abp.BackgroundTasks.DistributedLocking; +using LINGYUN.Abp.BackgroundTasks.ExceptionHandling; using LINGYUN.Abp.BackgroundTasks.Quartz; +using LINGYUN.Abp.Dapr.Client.Wrapper; using LINGYUN.Abp.EventBus.CAP; using LINGYUN.Abp.ExceptionHandling.Emailing; +using LINGYUN.Abp.Http.Client.Wrapper; using LINGYUN.Abp.LocalizationManagement.EntityFrameworkCore; using LINGYUN.Abp.Saas.EntityFrameworkCore; using LINGYUN.Abp.Serilog.Enrichers.Application; using LINGYUN.Abp.Serilog.Enrichers.UniqueId; using LINGYUN.Abp.TaskManagement.EntityFrameworkCore; +using LINGYUN.Abp.Webhooks.EventBus; using LINGYUN.Abp.Webhooks.Identity; using LINGYUN.Abp.Webhooks.Saas; using LINGYUN.Abp.WebhooksManagement; @@ -35,11 +37,6 @@ using Volo.Abp.Modularity; using Volo.Abp.PermissionManagement.EntityFrameworkCore; using Volo.Abp.SettingManagement.EntityFrameworkCore; using Volo.Abp.Swashbuckle; -using LINGYUN.Abp.Http.Client.Wrapper; -using LINGYUN.Abp.Dapr.Client.Wrapper; -using Microsoft.Extensions.DependencyInjection.Extensions; -using LINGYUN.Abp.Webhooks; -using LINGYUN.Abp.Webhooks.EventBus; namespace LY.MicroService.WebhooksManagement; @@ -103,17 +100,16 @@ public partial class WebhooksManagementHttpApiHostModule : AbpModule ConfigureBackgroundTasks(); ConfigureExceptionHandling(); ConfigureVirtualFileSystem(); + ConfigureFeatureManagement(); ConfigureCaching(configuration); ConfigureAuditing(configuration); ConfigureMultiTenancy(configuration); ConfigureSwagger(context.Services); + ConfigureWebhooks(context.Services); ConfigureOpenTelemetry(context.Services, configuration); ConfigureDistributedLock(context.Services, configuration); ConfigureSeedWorker(context.Services, hostingEnvironment.IsDevelopment()); ConfigureSecurity(context.Services, configuration, hostingEnvironment.IsDevelopment()); - - // 分布式事件发布者不在这个项目使用, 强制替换 - context.Services.Replace(ServiceDescriptor.Transient()); } public override void OnApplicationInitialization(ApplicationInitializationContext context) diff --git a/aspnet-core/services/LY.MicroService.WorkflowManagement.HttpApi.Host/WorkflowManagementHttpApiHostModule.cs b/aspnet-core/services/LY.MicroService.WorkflowManagement.HttpApi.Host/WorkflowManagementHttpApiHostModule.cs index c9309d141..c98b31cce 100644 --- a/aspnet-core/services/LY.MicroService.WorkflowManagement.HttpApi.Host/WorkflowManagementHttpApiHostModule.cs +++ b/aspnet-core/services/LY.MicroService.WorkflowManagement.HttpApi.Host/WorkflowManagementHttpApiHostModule.cs @@ -112,7 +112,6 @@ public partial class WorkflowManagementHttpApiHostModule : AbpModule ConfigureCors(context.Services, configuration); ConfigureBlobStoring(context.Services, configuration); ConfigureDistributedLock(context.Services, configuration); - ConfigureSeedWorker(context.Services, hostingEnvironment.IsDevelopment()); ConfigureSecurity(context.Services, configuration, hostingEnvironment.IsDevelopment()); context.Services.AddRazorPages(); diff --git a/aspnet-core/services/LY.MicroService.identityServer.HttpApi.Host/IdentityServerHttpApiHostModule.Configure.cs b/aspnet-core/services/LY.MicroService.identityServer.HttpApi.Host/IdentityServerHttpApiHostModule.Configure.cs index 5220cc915..bbcdccb6e 100644 --- a/aspnet-core/services/LY.MicroService.identityServer.HttpApi.Host/IdentityServerHttpApiHostModule.Configure.cs +++ b/aspnet-core/services/LY.MicroService.identityServer.HttpApi.Host/IdentityServerHttpApiHostModule.Configure.cs @@ -23,6 +23,7 @@ using Volo.Abp.Authorization.Permissions; using Volo.Abp.Caching; using Volo.Abp.Domain.Entities.Events.Distributed; using Volo.Abp.EntityFrameworkCore; +using Volo.Abp.FeatureManagement; using Volo.Abp.GlobalFeatures; using Volo.Abp.Identity.Localization; using Volo.Abp.Json; @@ -111,6 +112,14 @@ public partial class IdentityServerHttpApiHostModule }); } + private void ConfigureFeatureManagement() + { + Configure(options => + { + options.IsDynamicFeatureStoreEnabled = true; + }); + } + private void ConfigurePermissionManagement() { Configure(options => diff --git a/aspnet-core/services/LY.MicroService.identityServer.HttpApi.Host/IdentityServerHttpApiHostModule.cs b/aspnet-core/services/LY.MicroService.identityServer.HttpApi.Host/IdentityServerHttpApiHostModule.cs index 865c20707..07ba75184 100644 --- a/aspnet-core/services/LY.MicroService.identityServer.HttpApi.Host/IdentityServerHttpApiHostModule.cs +++ b/aspnet-core/services/LY.MicroService.identityServer.HttpApi.Host/IdentityServerHttpApiHostModule.cs @@ -84,6 +84,7 @@ public partial class IdentityServerHttpApiHostModule : AbpModule ConfigureJsonSerializer(); ConfigreExceptionHandling(); ConfigureVirtualFileSystem(); + ConfigureFeatureManagement(); ConfigurePermissionManagement(); ConfigureUrls(configuration); ConfigureCaching(configuration); diff --git a/aspnet-core/services/LY.MicroService.identityServer.HttpApi.Host/LY.MicroService.identityServer.HttpApi.Host.csproj b/aspnet-core/services/LY.MicroService.identityServer.HttpApi.Host/LY.MicroService.identityServer.HttpApi.Host.csproj index fddf04ef2..94c13e1a4 100644 --- a/aspnet-core/services/LY.MicroService.identityServer.HttpApi.Host/LY.MicroService.identityServer.HttpApi.Host.csproj +++ b/aspnet-core/services/LY.MicroService.identityServer.HttpApi.Host/LY.MicroService.identityServer.HttpApi.Host.csproj @@ -38,6 +38,7 @@ + diff --git a/aspnet-core/services/LY.MicroService.identityServer/IdentityServerModule.Configure.cs b/aspnet-core/services/LY.MicroService.identityServer/IdentityServerModule.Configure.cs index 555f0e4fd..4bba3d848 100644 --- a/aspnet-core/services/LY.MicroService.identityServer/IdentityServerModule.Configure.cs +++ b/aspnet-core/services/LY.MicroService.identityServer/IdentityServerModule.Configure.cs @@ -23,6 +23,7 @@ using Volo.Abp.Account.Localization; using Volo.Abp.Auditing; using Volo.Abp.Caching; using Volo.Abp.EntityFrameworkCore; +using Volo.Abp.FeatureManagement; using Volo.Abp.GlobalFeatures; using Volo.Abp.IdentityServer; using Volo.Abp.Json; @@ -120,6 +121,14 @@ public partial class IdentityServerModule }); } + private void ConfigureFeatureManagement() + { + Configure(options => + { + options.IsDynamicFeatureStoreEnabled = true; + }); + } + private void ConfigureJsonSerializer() { // 统一时间日期格式 diff --git a/aspnet-core/services/LY.MicroService.identityServer/IdentityServerModule.cs b/aspnet-core/services/LY.MicroService.identityServer/IdentityServerModule.cs index 0e4693734..712daf95f 100644 --- a/aspnet-core/services/LY.MicroService.identityServer/IdentityServerModule.cs +++ b/aspnet-core/services/LY.MicroService.identityServer/IdentityServerModule.cs @@ -98,6 +98,7 @@ public partial class IdentityServerModule : AbpModule ConfigureCaching(configuration); ConfigureIdentity(configuration); ConfigureVirtualFileSystem(); + ConfigureFeatureManagement(); ConfigureLocalization(); ConfigureAuditing(); ConfigureDataSeeder(); diff --git a/aspnet-core/tests/LINGYUN.Abp.EntityFrameworkCore.Tests/Properties/launchSettings.json b/aspnet-core/tests/LINGYUN.Abp.EntityFrameworkCore.Tests/Properties/launchSettings.json deleted file mode 100644 index 8aa9e542e..000000000 --- a/aspnet-core/tests/LINGYUN.Abp.EntityFrameworkCore.Tests/Properties/launchSettings.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "profiles": { - "WSL": { - "commandName": "WSL2", - "distributionName": "" - } - } -} \ No newline at end of file