Akka.NET 远程配置设置
Akka.NET Configuration settings for remoting
我正在使用 Akka.NET github 上的示例来尝试一些基本的远程处理。
在 GitHub 提供的远程示例中,Akka.NET 的配置字符串中有以下部分。
deployment {
/localactor {
router = round-robin-pool
nr-of-instances = 5
}
/remoteactor {
router = round-robin-pool
nr-of-instances = 5
remote = ""akka.tcp://system2@localhost:666""
}
}
remote {
dot-netty.tcp {
port = 1234
hostname = localhost
}
正斜杠 / 表示什么?这是评论还是只是文件的格式?
路由器选项'round-robin-pool'控制什么?我可以看到它映射到 following class 但我希望有人可以解释 akka.routing 在远程处理场景中的实际含义?我假设这与 url 或 ips 的映射方式有关?
如有任何说明,我们将不胜感激。
考虑示例中的以下片段:
/localactor {
router = round-robin-pool
nr-of-instances = 5
}
What does the forward slash / indicate? is this a comment or is this just the format of the files?
正斜杠不是注释;它表示演员的名字。示例中的 code 通过以下方式引用名为 localactor
的演员:
var local = system.ActorOf(Props.Create(() => new SomeActor("hello", 123)).WithRouter(FromConfig.Instance), "localactor");
What does the router option 'round-robin-pool' control? I can see that it maps to the following class but I am hoping someone can explain what akka.routing actually means in the context of a remoting scenario? I am assuming this has something to do with how urls or ips are mapped?
round-robin-pool
用于定义一个router. localactor
in the above configuration snippet is a router actor that creates a pool of five routee instances to which it routes messages in round-robin顺序。路由器在远程上下文中没有特殊意义;它本质上与非远程场景中的路由器没有什么不同。您可以在链接的文档中阅读有关路由器的更多信息。
我正在使用 Akka.NET github 上的示例来尝试一些基本的远程处理。
在 GitHub 提供的远程示例中,Akka.NET 的配置字符串中有以下部分。
deployment {
/localactor {
router = round-robin-pool
nr-of-instances = 5
}
/remoteactor {
router = round-robin-pool
nr-of-instances = 5
remote = ""akka.tcp://system2@localhost:666""
}
}
remote {
dot-netty.tcp {
port = 1234
hostname = localhost
}
正斜杠 / 表示什么?这是评论还是只是文件的格式?
路由器选项'round-robin-pool'控制什么?我可以看到它映射到 following class 但我希望有人可以解释 akka.routing 在远程处理场景中的实际含义?我假设这与 url 或 ips 的映射方式有关?
如有任何说明,我们将不胜感激。
考虑示例中的以下片段:
/localactor {
router = round-robin-pool
nr-of-instances = 5
}
What does the forward slash / indicate? is this a comment or is this just the format of the files?
正斜杠不是注释;它表示演员的名字。示例中的 code 通过以下方式引用名为 localactor
的演员:
var local = system.ActorOf(Props.Create(() => new SomeActor("hello", 123)).WithRouter(FromConfig.Instance), "localactor");
What does the router option 'round-robin-pool' control? I can see that it maps to the following class but I am hoping someone can explain what akka.routing actually means in the context of a remoting scenario? I am assuming this has something to do with how urls or ips are mapped?
round-robin-pool
用于定义一个router. localactor
in the above configuration snippet is a router actor that creates a pool of five routee instances to which it routes messages in round-robin顺序。路由器在远程上下文中没有特殊意义;它本质上与非远程场景中的路由器没有什么不同。您可以在链接的文档中阅读有关路由器的更多信息。