| 
						
						
							
								
							
						
						
					 | 
					 | 
					@ -27,7 +27,7 @@ namespace ZeroLevel.Network
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					        public ExServiceHost(IDiscoveryClient client)
 | 
					 | 
					 | 
					 | 
					        public ExServiceHost(IDiscoveryClient client)
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					        {
 | 
					 | 
					 | 
					 | 
					        {
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					            _discoveryClient = client;
 | 
					 | 
					 | 
					 | 
					            _discoveryClient = client;
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					            _registerTaskKey = Sheduller.RemindEvery(TimeSpan.FromMilliseconds(50), TimeSpan.FromSeconds(15), RegisterServicesInDiscovery);
 | 
					 | 
					 | 
					 | 
					            _registerTaskKey = Sheduller.RemindEvery(TimeSpan.FromMilliseconds(50), TimeSpan.FromSeconds(55), RegisterServicesInDiscovery);
 | 
				
			
			
				
				
			
		
	
		
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					        }
 | 
					 | 
					 | 
					 | 
					        }
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					
 | 
					 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					        public IExService RegisterService(IExchangeService service)
 | 
					 | 
					 | 
					 | 
					        public IExService RegisterService(IExchangeService service)
 | 
				
			
			
		
	
	
		
		
			
				
					| 
						
						
						
							
								
							
						
					 | 
					 | 
					@ -47,6 +47,7 @@ namespace ZeroLevel.Network
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                    Server = server,
 | 
					 | 
					 | 
					 | 
					                    Server = server,
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                    ServiceInfo = new ExServiceInfo
 | 
					 | 
					 | 
					 | 
					                    ServiceInfo = new ExServiceInfo
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                    {
 | 
					 | 
					 | 
					 | 
					                    {
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					                        Port = server.Endpoint.Port,
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        ServiceKey = service.Key,
 | 
					 | 
					 | 
					 | 
					                        ServiceKey = service.Key,
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        Version = service.Version,
 | 
					 | 
					 | 
					 | 
					                        Version = service.Version,
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        ServiceGroup = service.Group,
 | 
					 | 
					 | 
					 | 
					                        ServiceGroup = service.Group,
 | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
					 | 
					@ -88,6 +89,7 @@ namespace ZeroLevel.Network
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                    Server = server,
 | 
					 | 
					 | 
					 | 
					                    Server = server,
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                    ServiceInfo = new ExServiceInfo
 | 
					 | 
					 | 
					 | 
					                    ServiceInfo = new ExServiceInfo
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                    {
 | 
					 | 
					 | 
					 | 
					                    {
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					                        Port = server.Endpoint.Port,
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        ServiceKey = serviceInfo.ServiceKey,
 | 
					 | 
					 | 
					 | 
					                        ServiceKey = serviceInfo.ServiceKey,
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        Version = serviceInfo.Version,
 | 
					 | 
					 | 
					 | 
					                        Version = serviceInfo.Version,
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        ServiceGroup = serviceInfo.ServiceGroup,
 | 
					 | 
					 | 
					 | 
					                        ServiceGroup = serviceInfo.ServiceGroup,
 | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
					 | 
					@ -329,7 +331,7 @@ namespace ZeroLevel.Network
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                IExClient transport;
 | 
					 | 
					 | 
					 | 
					                IExClient transport;
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                try
 | 
					 | 
					 | 
					 | 
					                try
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                {
 | 
					 | 
					 | 
					 | 
					                {
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                    transport = ExchangeTransportFactory.GetClient(service.Endpoint);
 | 
					 | 
					 | 
					 | 
					                    transport = ExchangeTransportFactory.GetClientWithCache(service.Endpoint);
 | 
				
			
			
				
				
			
		
	
		
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                }
 | 
					 | 
					 | 
					 | 
					                }
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                catch (Exception ex)
 | 
					 | 
					 | 
					 | 
					                catch (Exception ex)
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                {
 | 
					 | 
					 | 
					 | 
					                {
 | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
					 | 
					@ -374,7 +376,7 @@ namespace ZeroLevel.Network
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					            IExClient transport;
 | 
					 | 
					 | 
					 | 
					            IExClient transport;
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					            try
 | 
					 | 
					 | 
					 | 
					            try
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					            {
 | 
					 | 
					 | 
					 | 
					            {
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                transport = ExchangeTransportFactory.GetClient(candidate.Endpoint);
 | 
					 | 
					 | 
					 | 
					                transport = ExchangeTransportFactory.GetClientWithCache(candidate.Endpoint);
 | 
				
			
			
				
				
			
		
	
		
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					            }
 | 
					 | 
					 | 
					 | 
					            }
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					            catch (Exception ex)
 | 
					 | 
					 | 
					 | 
					            catch (Exception ex)
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					            {
 | 
					 | 
					 | 
					 | 
					            {
 | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
					 | 
					@ -405,7 +407,7 @@ namespace ZeroLevel.Network
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        IExClient transport;
 | 
					 | 
					 | 
					 | 
					                        IExClient transport;
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        try
 | 
					 | 
					 | 
					 | 
					                        try
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        {
 | 
					 | 
					 | 
					 | 
					                        {
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                            transport = ExchangeTransportFactory.GetClient(service.Endpoint);
 | 
					 | 
					 | 
					 | 
					                            transport = ExchangeTransportFactory.GetClientWithCache(service.Endpoint);
 | 
				
			
			
				
				
			
		
	
		
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        }
 | 
					 | 
					 | 
					 | 
					                        }
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        catch (Exception ex)
 | 
					 | 
					 | 
					 | 
					                        catch (Exception ex)
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        {
 | 
					 | 
					 | 
					 | 
					                        {
 | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
					 | 
					@ -443,7 +445,7 @@ namespace ZeroLevel.Network
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        IExClient transport;
 | 
					 | 
					 | 
					 | 
					                        IExClient transport;
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        try
 | 
					 | 
					 | 
					 | 
					                        try
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        {
 | 
					 | 
					 | 
					 | 
					                        {
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                            transport = ExchangeTransportFactory.GetClient(service.Endpoint);
 | 
					 | 
					 | 
					 | 
					                            transport = ExchangeTransportFactory.GetClientWithCache(service.Endpoint);
 | 
				
			
			
				
				
			
		
	
		
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        }
 | 
					 | 
					 | 
					 | 
					                        }
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        catch (Exception ex)
 | 
					 | 
					 | 
					 | 
					                        catch (Exception ex)
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        {
 | 
					 | 
					 | 
					 | 
					                        {
 | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
					 | 
					@ -481,7 +483,7 @@ namespace ZeroLevel.Network
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        IExClient transport;
 | 
					 | 
					 | 
					 | 
					                        IExClient transport;
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        try
 | 
					 | 
					 | 
					 | 
					                        try
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        {
 | 
					 | 
					 | 
					 | 
					                        {
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                            transport = ExchangeTransportFactory.GetClient(service.Endpoint);
 | 
					 | 
					 | 
					 | 
					                            transport = ExchangeTransportFactory.GetClientWithCache(service.Endpoint);
 | 
				
			
			
				
				
			
		
	
		
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        }
 | 
					 | 
					 | 
					 | 
					                        }
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        catch (Exception ex)
 | 
					 | 
					 | 
					 | 
					                        catch (Exception ex)
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        {
 | 
					 | 
					 | 
					 | 
					                        {
 | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
						
					 | 
					 | 
					
 
 |