消费者cultureInfo 自动处理,消费成功自动设置事件状态
continuous-integration/drone/push Build is passing

This commit is contained in:
hang
2024-10-11 19:43:15 +08:00
parent 79fd83449a
commit f67ebce739
5 changed files with 39 additions and 42 deletions
+2 -1
View File
@@ -36,6 +36,7 @@ using IRaCIS.Core.Application.MassTransit.Consumer;
using DocumentFormat.OpenXml.InkML;
using IRaCIS.Core.Domain;
using MassTransit.Internals;
using IRaCIS.Core.Domain.BaseModel;
AppContext.SetSwitch("Npgsql.EnableLegacyTimestampBehavior", true);
AppContext.SetSwitch("Npgsql.DisableDateTimeInfinityConversions", true);
@@ -184,7 +185,7 @@ builder.Services.AddMassTransit(cfg =>
cfg.UseHangfireScheduler();
cfg.UseConsumeFilter(typeof(CultureInfoFilter<>), context,
x => x.Include(type => type.HasInterface(typeof(IConsumer<>))));
x => x.Include(type => type.IsAssignableTo(typeof(DomainEvent))));
// 这里可以进行额外的配置