Documentation ¶
Index ¶
- Constants
- func AgentAuthTokenSecretName(clusterName string) string
- func ClusterLabels(c *scyllav1.ScyllaCluster) map[string]string
- func CrossNamespaceServiceNameForCluster(c *scyllav1.ScyllaCluster) string
- func DatacenterLabels(c *scyllav1.ScyllaCluster) map[string]string
- func FindContainerWithName(containers []corev1.Container, name string) (int, error)
- func FindScyllaContainer(containers []corev1.Container) (int, error)
- func FindSidecarInjectorContainer(containers []corev1.Container) (int, error)
- func HeadlessServiceNameForCluster(c *scyllav1.ScyllaCluster) string
- func ImageToVersion(image string) (string, error)
- func IndexFromName(n string) (int32, error)
- func ManagerClusterName(c *scyllav1.ScyllaCluster) string
- func ManagerSelector() labels.Selector
- func MemberServiceName(r scyllav1.RackSpec, c *scyllav1.ScyllaCluster, idx int) string
- func ObjRef(obj metav1.Object) string
- func PVCNameForPod(podName string) string
- func PVCNameForService(svcName string) string
- func PVCNameForStatefulSet(stsName string, ordinal int32) string
- func PVCNamePrefixForScyllaCluster(scName string) string
- func PodDisruptionBudgetName(c *scyllav1.ScyllaCluster) string
- func RackLabels(r scyllav1.RackSpec, c *scyllav1.ScyllaCluster) map[string]string
- func RackSelector(r scyllav1.RackSpec, c *scyllav1.ScyllaCluster) labels.Selector
- func ScyllaVersion(containers []corev1.Container) (string, error)
- func SelectorForSeeds(clusterName string) string
- func ServiceAccountNameForMembers(c *scyllav1.ScyllaCluster) string
- func ServiceDNSName(service string, c *scyllav1.ScyllaCluster) string
- func ServiceNameFromPod(pod *corev1.Pod) string
- func SidecarVersion(containers []corev1.Container) (string, error)
- func StatefulSetNameForRack(r scyllav1.RackSpec, c *scyllav1.ScyllaCluster) string
- func StatefulSetPodLabel(name string) map[string]string
Constants ¶
const ( // SeedLabel determines if a member is a seed or not. SeedLabel = "scylla/seed" // DecommissionedLabel expresses the intent to decommission // the specific member. The presence of the label expresses // the intent to decommission. If the value is true, it means // the member has finished decommissioning. // Values: {true, false} DecommissionedLabel = "scylla/decommissioned" // ReplaceLabel express the intent to replace pod under the specific member. ReplaceLabel = "scylla/replace" // NodeMaintenanceLabel means that node is under maintenance. // Readiness check will always fail when this label is added to member service. NodeMaintenanceLabel = "scylla/node-maintenance" LabelValueTrue = "true" LabelValueFalse = "false" )
These labels are only used on the ClusterIP services acting as each member's identity (static ip). Each of these labels is a record of intent to do something. The controller sets these labels and each member watches for them and takes the appropriate actions.
See the sidecar design doc for more details.
const ( ClusterNameLabel = "scylla/cluster" DatacenterNameLabel = "scylla/datacenter" RackNameLabel = "scylla/rack" ScyllaVersionLabel = "scylla/scylla-version" ManagedHash = "scylla-operator.scylladb.com/managed-hash" AppName = "scylla" OperatorAppName = "scylla-operator" ManagerAppName = "scylla-manager" PrometheusScrapeAnnotation = "prometheus.io/scrape" PrometheusPortAnnotation = "prometheus.io/port" ForceRedeploymentReasonAnnotation = "scylla-operator.scylladb.com/force-redeployment-reason" )
Generic Labels used on objects created by the operator.
const ( ScyllaContainerName = "scylla" SidecarInjectorContainerName = "sidecar-injection" PVCTemplateName = "data" ScyllaConfigDirName = "/mnt/scylla-config" ScyllaAgentConfigDirName = "/mnt/scylla-agent-config" ScyllaAgentConfigFileName = "scylla-manager-agent.yaml" ScyllaAgentAuthTokenFileName = "auth-token.yaml" ScyllaAgentConfigDefaultFile = "/etc/scylla-manager-agent/scylla-manager-agent.yaml" ScyllaClientConfigDirName = "/mnt/scylla-client-config" ScyllaClientConfigFileName = "scylla-client.yaml" ScyllaConfigName = "scylla.yaml" ScyllaRackDCPropertiesName = "cassandra-rackdc.properties" ScyllaIOPropertiesName = "io_properties.yaml" DataDir = "/var/lib/scylla" ReadinessProbePath = "/readyz" LivenessProbePath = "/healthz" ProbePort = 8080 MetricsPort = 8081 OperatorEnvVarPrefix = "SCYLLA_OPERATOR_" )
Configuration Values
const ( ScyllaManagerNamespace = "scylla-manager" ScyllaManagerServiceName = "scylla-manager" )
Variables ¶
This section is empty.
Functions ¶
func AgentAuthTokenSecretName ¶ added in v1.3.0
func ClusterLabels ¶
func ClusterLabels(c *scyllav1.ScyllaCluster) map[string]string
ClusterLabels returns a map of label keys and values for the given Cluster.
func CrossNamespaceServiceNameForCluster ¶ added in v0.3.0
func CrossNamespaceServiceNameForCluster(c *scyllav1.ScyllaCluster) string
func DatacenterLabels ¶
func DatacenterLabels(c *scyllav1.ScyllaCluster) map[string]string
DatacenterLabels returns a map of label keys and values for the given Datacenter.
func FindContainerWithName ¶ added in v1.1.0
FindContainerWithName returns container having
func FindScyllaContainer ¶
FindScyllaContainer returns Scylla container from given list.
func FindSidecarInjectorContainer ¶ added in v1.1.0
FindSidecarInjectorContainer returns sidecar injector container from given list.
func HeadlessServiceNameForCluster ¶
func HeadlessServiceNameForCluster(c *scyllav1.ScyllaCluster) string
func ImageToVersion ¶
ImageToVersion strips version part from container image.
func IndexFromName ¶
IndexFromName attempts to get the index from a name using the naming convention <name>-<index>.
func ManagerClusterName ¶ added in v0.3.0
func ManagerClusterName(c *scyllav1.ScyllaCluster) string
func ManagerSelector ¶ added in v0.3.0
func MemberServiceName ¶ added in v1.0.0
func PVCNameForPod ¶
func PVCNameForService ¶ added in v1.4.0
func PVCNameForStatefulSet ¶ added in v1.4.0
func PVCNamePrefixForScyllaCluster ¶ added in v1.4.0
func PodDisruptionBudgetName ¶ added in v1.2.0
func PodDisruptionBudgetName(c *scyllav1.ScyllaCluster) string
func RackLabels ¶
RackLabels returns a map of label keys and values for the given Rack.
func RackSelector ¶
RackSelector returns a LabelSelector for the given rack.
func ScyllaVersion ¶ added in v1.1.0
ScyllaVersion returns version of Scylla container.
func SelectorForSeeds ¶
func ServiceAccountNameForMembers ¶
func ServiceAccountNameForMembers(c *scyllav1.ScyllaCluster) string
func ServiceDNSName ¶ added in v1.0.0
func ServiceDNSName(service string, c *scyllav1.ScyllaCluster) string
func ServiceNameFromPod ¶ added in v1.0.0
func SidecarVersion ¶ added in v1.1.0
SidecarVersion returns version of sidecar container.
func StatefulSetNameForRack ¶
func StatefulSetNameForRack(r scyllav1.RackSpec, c *scyllav1.ScyllaCluster) string
func StatefulSetPodLabel ¶
StatefulSetPodLabel returns a map of labels to uniquely identify a StatefulSet Pod with the given name
Types ¶
This section is empty.