cql

package
v0.6.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 21, 2026 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ReplicationClassNetworkTopologyStrategy = "org.apache.cassandra.locator.NetworkTopologyStrategy"
	ReplicationClassSimpleTopologyStrategy  = "org.apache.cassandra.locator.SimpleTopologyStrategy"
)

Variables

This section is empty.

Functions

func ReplicationQuery

func ReplicationQuery(rfOptions map[string]string) string

Types

type CqlClient

type CqlClient interface {
	GetKeyspacesInfo() ([]Keyspace, error)
	UpdateRF(keyspaceName string, strategyOptions map[string]string) error
	GetRoles() ([]Role, error)
	CreateRole(role Role) error
	UpdateRole(role Role) error
	UpdateRolePassword(roleName, newPassword string) error
	Query(stmt string, values ...interface{}) error
	DropRole(role Role) error
	CloseSession()
}

func NewCQLClient

func NewCQLClient(clusterConfig *gocql.ClusterConfig) (CqlClient, error)

type Keyspace

type Keyspace struct {
	Name        string
	Replication map[string]string
}

type Role

type Role struct {
	Role  string
	Super bool
	Login bool
	// empty when retrieving roles. Only used when create/update a role.
	Password string
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL