コード例 #1
0
ファイル: Config.cs プロジェクト: sbacquet/Hexagon
 public Config()
 {
     Port       = 0;
     Assemblies = new List <string>();
     NodeConfig = new AkkaNodeConfig();
     RequestTimeoutInSeconds = 10;
 }
コード例 #2
0
        MessageSystem <XmlMessage, XmlMessagePattern> CreateSystem(AkkaNodeConfig config)
        {
            switch (ImplType)
            {
            case EImplType.Akka:
                return(AkkaXmlMessageSystem.Create(config));

            default:
                throw new ArgumentException("only Akka implementation type is handled");
            }
        }
コード例 #3
0
 private void Join(RoleName from, RoleName to)
 {
     RunOn(() =>
     {
         Cluster.Join(Node(to).Address);
         _nodeConfig = new AkkaNodeConfig(from.Name)
         {
             GossipTimeFrameInSeconds = 5
         };
         _messageSystem = AkkaXmlMessageSystem.Create(this.Sys);
     }, from);
     EnterBarrier(from.Name + "-joined");
 }
コード例 #4
0
 private void Join(RoleName from, RoleName to)
 {
     RunOn(() =>
     {
         Cluster.Join(Node(to).Address);
         _nodeConfig = new AkkaNodeConfig(from.Name)
         {
             GossipTimeFrameInSeconds = 5
         };
         if (from.Name == "deployer")
         {
             _nodeConfig.AddThisAssembly();
             _nodeConfig.SetProcessingUnitProps(new NodeConfig.ProcessingUnitProps("routed")
             {
                 RouteOnNodeRole = "routeHere", TotalMaxClusterRoutees = 3, AllowLocalRoutee = true
             });
         }
         _messageSystem = AkkaXmlMessageSystem.Create(this.Sys);
     }, from);
     EnterBarrier(from.Name + "-joined");
 }