protected NodeBase(ICluster owner, IPEndPoint endpoint, ISocket socket, IFailurePolicyFactory failurePolicyFactory) { this.owner = owner ?? throw new ArgumentNullException(nameof(owner)); this.endpoint = endpoint ?? throw new ArgumentNullException(nameof(endpoint)); this.socket = socket; name = endpoint.ToString(); failLock = new object(); writeQueue = new ConcurrentQueue <OpQueueEntry>(); readQueue = new Queue <OpQueueEntry>(); IsAlive = true; mustReconnect = true; flushWriteBufferAction = FlushWriteBufferRequest; tryAskForMoreDataAction = TryAskForMoreDataRequest; failurePolicy = (failurePolicyFactory ?? throw new ArgumentNullException(nameof(failurePolicyFactory))).Create(this); npm = new NodePerformanceMonitor(name); }
public MemcachedNode(MemoryPool <byte> allocator, ICluster owner, IPEndPoint endpoint, ISocket socket, IFailurePolicyFactory failurePolicyFactory) : base(owner, endpoint, socket, failurePolicyFactory) { this.allocator = allocator; }
public FailNode(ICluster owner, IPEndPoint endpoint, ISocket socket, IFailurePolicyFactory failurePolicyFactory) : base(owner, endpoint, socket, failurePolicyFactory) { }