class Cassandra::DBApi::Cluster
- Cassandra::DBApi::Cluster
- Reference
- Object
Overview
Represents a Cassandra cluster. Stores connection parameters like host and port. A single cluster can be used to create many sessions so a custom reference counting mechanism is used to track and destroy sessions as needed.
Defined in:
cassandra/dbapi/cluster.crConstructors
-
.new(context : DB::ConnectionContext)
Initialises a cluster object with the supplied host and port from the context.
Class Method Summary
Instance Method Summary
-
#do_close
Close the connection.
- #paging_size : UInt64?
Constructor Detail
def self.new(context : DB::ConnectionContext)
#
Initialises a cluster object with the supplied host and port from the context.
Class Method Detail
Instance Method Detail
def do_close
#
Close the connection.
Disposes the cluster when the last reference is removed. Needs to be called to prevent memory leaks.