예제 #1
0
        public ChronokeeperService GetChronokeeperService(RyuContainer ryu)
        {
            var remoteChronokeeperConfiguration = ryu.Get <RemoteChronokeeperConfiguration>();
            var networkingProxy      = ryu.Get <INetworkingProxy>();
            var endpoint             = networkingProxy.CreateEndPoint(remoteChronokeeperConfiguration.Host, remoteChronokeeperConfiguration.Port);
            var serviceClientFactory = ryu.Get <ServiceClientFactory>();
            var serviceClient        = serviceClientFactory.Remote(endpoint.ToIPEndPoint());

            return(serviceClient.GetService <ChronokeeperService>());
        }
예제 #2
0
        public RemoteChronokeeperConfiguration GetRemoteChronokeeperConfiguration(RyuContainer ryu)
        {
            var configurationFactory = ryu.Get <RemoteChronokeeperConfigurationFactory>();

            return(configurationFactory.Create());
        }