开发者

How to NServiceBus Publish() in Fixed interval

Is it possble to configure the Publisher to run in fixed interval, say every hour? In the example I downloaded from the NServiceBus web site, the publisher publishes whenever a user hit enter key. So, instead of that, I 开发者_如何学编程would like to publish a message every hour.

Thanks.


You can set up a timer from an IWantToRunAtStartup class's Run method. Then publish to the bus every time the timer fires.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜