【问题标题】:max number of actors per host in akkaakka 中每个主机的最大演员数
【发布时间】:2013-09-30 03:28:40
【问题描述】:

在 akka 的一个盒子上最多可以有多少个演员?

public void MyActor extends AkkaActor{

  receive(Objet obj){
    // so something
  } 

}

1)Is there some limit on max number of actors instances?I am planning to created around 10K actors on one box. I will have 50 such boxes so that i can scale horizontally
2)IS there some performance problems with this?

【问题讨论】:

    标签: java akka akka-cluster


    【解决方案1】:

    这只是拥有足够内存的问题:一个演员的开销大约是 400 字节(加上你保留在其中的任何状态)。这意味着在典型系统上,您可以拥有数百万个演员。性能不取决于您创建的演员数量,而是取决于您在他们之间发送的消息数量。如果这个数字达到每秒几百万,您不必担心,除此之外,您必须针对您选择的硬件对您的程序进行基准测试,看看它是否有效。

    【讨论】:

    • 感谢您的回复。我尝试使用 AKAA 的原因是我希望像我原来的帖子中提到的那样让演员跨框。然后我想轻松地在这些演员之间进行交流。
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2013-02-06
    • 1970-01-01
    • 2019-04-23
    • 2013-07-20
    • 2014-03-09
    • 2019-01-16
    • 2015-03-25
    相关资源
    最近更新 更多