简体   繁体   English

是否可以将调度程序限制为 Akka.Net 中的一个演员

[英]Is it possible to limit the scheduler to one actor in Akka.Net

I need to send a message to actor on periodic bases.我需要定期向演员发送消息。 Based on the cluster configurations, there are 3 nodes available.根据集群配置,有 3 个节点可用。 So every actor in the node is scheduling the message.所以节点中的每个参与者都在调度消息。 But I want one actor to do this job so that I can avoid reprocessing and duplicate processing.但我希望一个演员来做这项工作,这样我就可以避免重新处理和重复处理。

Is there any way that we can schedule a message or a task from Cluster or any other way to solve this problem.有什么办法可以从 Cluster 中安排消息或任务或任何其他方式来解决此问题。

I think you can make a cluster singleton , that way you will only have one of that actor type.我认为您可以创建一个 集群单例,这样您将只有一种演员类型。 For scheduling you can use Quartz Actor对于调度,您可以使用Quartz Actor

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM