private bool TryGetClient(string key, out MemcachedSharpClient client)
        {
            MemcachedSharpClient server;

            if (_nodes.TryGetNode(key, out server))
            {
                Debug.WriteLine("Selected server: " + server.EndPoint);
                if (!server.IsAlive)
                {
                    Debug.WriteLine("Server: " + server.EndPoint + " is dead. Selecting the next one");
                    if (!_clients.Any(a => a.IsAlive))
                    {
                        client = null;
                        return(false);
                    }
                    var index        = _clients.IndexOf(server);
                    var initialIndex = index;

                    if (++index >= _clients.Count)
                    {
                        index = 0;
                    }

                    while (!(server = _clients[index++]).IsAlive)
                    {
                        if (index == initialIndex) //We're right back where we started. No server is online.
                        {
                            Debug.WriteLine("No server is up. Returning null-server");
                            client = null;
                            return(false);
                        }
                    }

                    Debug.WriteLine("Failing over to: " + server.EndPoint);
                }

                client = server;
                return(true);
            }

            client = null;
            return(false);
        }
 protected bool Equals(MemcachedSharpClient other)
 {
     return(string.Equals(EndPoint, other.EndPoint));
 }