stargate

package
v1.9.0 Latest Latest
Warning

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

Go to latest
Published: Sep 20, 2023 License: Apache-2.0 Imports: 24 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AuthKeyspace = "data_endpoint_auth"
	AuthTable    = "token"
)
View Source
const (
	DefaultImageRepository = "stargateio"
	DefaultImageName3      = "stargate-3_11"
	DefaultImageName4      = "stargate-4_0"
	DefaultVersion         = "1.0.67"
)
View Source
const (
	MetricsPort         = 8084
	VectorContainerName = "stargate-vector-agent"
)
View Source
const CqlConfigName = "stargate-cql.yaml"

Variables

View Source
var CassandraYamlRetainedSettings = []string{"server_encryption_options"}
View Source
var CqlYamlRetainedSettings = []string{
	"rpc_keepalive",
	"native_transport_max_frame_size_in_mb",
	"native_transport_max_concurrent_connections",
	"native_transport_max_concurrent_connections_per_ip",
	"native_transport_flush_in_batches_legacy",
	"native_transport_allow_older_protocols",
	"native_transport_max_concurrent_requests_in_bytes_per_ip",
	"native_transport_max_concurrent_requests_in_bytes",
	"native_transport_idle_timeout_in_ms",
	"client_encryption_options",
}

Functions

func CreateStargateConfigMap

func CreateStargateConfigMap(namespace, cassandraYaml, stargateCqlYaml string, dc cassdcapi.CassandraDatacenter) *corev1.ConfigMap

func CreateVectorConfigMap added in v1.5.0

func CreateVectorConfigMap(namespace, vectorToml string, dc cassdcapi.CassandraDatacenter) *corev1.ConfigMap

func DeploymentName

func DeploymentName(dc *cassdcapi.CassandraDatacenter, rack *cassdcapi.Rack) string

func FilterConfig added in v1.4.0

func FilterConfig(config map[string]interface{}, retainedSettings []string) map[string]interface{}

func GeneratedConfigMapName

func GeneratedConfigMapName(clusterName, dcName string) string

func MergeYamlString added in v1.4.0

func MergeYamlString(userConfigMap string, generatedConfigMap string) string

func NewDeployments

func NewDeployments(stargate *api.Stargate, dc *cassdcapi.CassandraDatacenter, logger logr.Logger) map[string]appsv1.Deployment

NewDeployments compute the Deployments to create for the given Stargate and CassandraDatacenter resources.

func NewService

func NewService(stargate *api.Stargate, dc *cassdcapi.CassandraDatacenter) *corev1.Service

NewService creates a Service object for the given Stargate and CassandraDatacenter resources.

func NewStargate added in v1.2.0

func ReconcileAuthKeyspace

func ReconcileAuthKeyspace(managementApi cassandra.ManagementApiFacade, replication map[string]int, logger logr.Logger) error

ReconcileAuthKeyspace ensures that the Stargate auth schema exists, has the appropriate replication, and contains the appropriate tables.

func ReconcileAuthTable

func ReconcileAuthTable(managementApi cassandra.ManagementApiFacade, logger logr.Logger) error

ReconcileAuthTable ensures that the Stargate auth schema contains the appropriate tables. Note that we don't do much here and currently, we only check if the token table exists, without checking if the table definition matches the expected one. If the auth schema becomes more complex in the future, we'd need to find a more robust solution, maybe à la Reaper.

func ResourceName

func ResourceName(dc *cassdcapi.CassandraDatacenter) string

func ServiceName

func ServiceName(dc *cassdcapi.CassandraDatacenter) string

func VectorAgentConfigMapName added in v1.5.0

func VectorAgentConfigMapName(clusterName, dcName string) string

VectorAgentConfigMapName generates a ConfigMap name based on the K8s sanitized cluster name and datacenter name.

Types

type ClusterVersion

type ClusterVersion string
const (
	ClusterVersion3 ClusterVersion = "3.11"
	ClusterVersion4 ClusterVersion = "4.0"
)

Jump to

Keyboard shortcuts

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