@@ -64,8 +64,12 @@ namespace IRaCIS.Core.Infra.EFCore.Interceptor
|
|||||||
//延迟调度的消息,比如1h后再消费
|
//延迟调度的消息,比如1h后再消费
|
||||||
await _scheduler.SchedulePublish(DateTime.Now.AddSeconds((int)domainEvent.DelaySeconds!), (object)domainEvent);
|
await _scheduler.SchedulePublish(DateTime.Now.AddSeconds((int)domainEvent.DelaySeconds!), (object)domainEvent);
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
await _publishEndpoint.Publish(domainEvent.GetType(), domainEvent);
|
await _publishEndpoint.Publish(domainEvent.GetType(), domainEvent);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user