Commit a391ba15 by 丁松杰

event 发送至 eventbus 后 event 在 storage 中的状态修改为 已发送

parent bf389e5b
Showing with 4 additions and 1 deletions
......@@ -57,7 +57,7 @@ namespace Pole.Core.EventBus
}
else
{
var mediumMessage = eventStorage.StoreMessage(eventEntity, Transaction.DbTransaction);
var mediumMessage = await eventStorage.StoreMessage(eventEntity, Transaction.DbTransaction);
if (Transaction.AutoCommit)
{
......@@ -66,6 +66,9 @@ namespace Pole.Core.EventBus
}
await producer.Publish(bytes);
await eventStorage.ChangePublishStateAsync(eventEntity,EventStatus.Published);
return true;
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment