internal CassandraClient(KeyspaceFactory keyspaceFactory, Endpoint endpoint, IKeyedObjectPool <Endpoint, ICassandraClient> pool) { this.mySerial = serial.Increment(); this.keyspaceFactory = keyspaceFactory; if (endpoint == null) { throw new ArgumentNullException("endpoint"); } if (!port.HasValue) { port = endpoint.Port; } if (port.Value != endpoint.Port) { if (this.pool != null) { this.pool.Clear(); } port = endpoint.Port; } this.Endpoint = endpoint; this.pool = pool; }
internal CassandraClient(KeyspaceFactory keyspaceFactory, Endpoint endpoint, IKeyedObjectPool<Endpoint, ICassandraClient> pool) { this.mySerial = serial.Increment(); this.keyspaceFactory = keyspaceFactory; if (endpoint == null) throw new ArgumentNullException("endpoint"); if (!port.HasValue) port = endpoint.Port; if (port.Value != endpoint.Port) { if (this.pool != null) this.pool.Clear(); port = endpoint.Port; } this.Endpoint = endpoint; this.pool = pool; }
internal CassandraClient(Apache.Cassandra.Cassandra.Iface thriftClient, KeyspaceFactory keyspaceFactory, Endpoint endpoint, IKeyedObjectPool<Endpoint, ICassandraClient> pool) : this(keyspaceFactory, endpoint, pool) { cassandra = thriftClient; }
internal CassandraClient(Apache.Cassandra.Cassandra.Iface thriftClient, KeyspaceFactory keyspaceFactory, Endpoint endpoint, IKeyedObjectPool <Endpoint, ICassandraClient> pool) : this(keyspaceFactory, endpoint, pool) { cassandra = thriftClient; }