mirror of
				https://github.com/nsnail/Ocelot.git
				synced 2025-11-04 09:15:27 +08:00 
			
		
		
		
	wip: removed some debug statements and all tests passing on my PC...feel there is something wrong with the service discovery test around task execution not completing
This commit is contained in:
		@@ -32,16 +32,14 @@ namespace Ocelot.LoadBalancer.LoadBalancers
 | 
			
		||||
 | 
			
		||||
        public Response Add(string key, ILoadBalancer loadBalancer)
 | 
			
		||||
        {
 | 
			
		||||
            try
 | 
			
		||||
            if (!_loadBalancers.ContainsKey(key))
 | 
			
		||||
            {
 | 
			
		||||
                _loadBalancers.Add(key, loadBalancer);
 | 
			
		||||
                return new OkResponse();
 | 
			
		||||
            }
 | 
			
		||||
            catch (System.Exception exception)
 | 
			
		||||
            {
 | 
			
		||||
                Console.WriteLine(exception.StackTrace);
 | 
			
		||||
                throw;
 | 
			
		||||
            }
 | 
			
		||||
 | 
			
		||||
            _loadBalancers.Remove(key);
 | 
			
		||||
            _loadBalancers.Add(key, loadBalancer);
 | 
			
		||||
            return new OkResponse();
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user