Documentation ¶
Index ¶
- Constants
- func AddTwemproxySidecar(podTemplateSpec corev1.PodTemplateSpec, ...) corev1.PodTemplateSpec
- func AddTwemproxyTaskSidecar(taskSpec pipelinev1beta1.TaskSpec, twemproxySpec *saasv1alpha1.TwemproxySpec) pipelinev1beta1.TaskSpec
- func NewOptions(spec saasv1alpha1.TwemproxySpec) *pod.Options
- func TwemproxyContainer(twemproxySpec *saasv1alpha1.TwemproxySpec) corev1.Container
- func TwemproxyContainerVolume(twemproxySpec *saasv1alpha1.TwemproxySpec) corev1.Volume
- type Server
- type ServerPoolConfig
Constants ¶
View Source
const ( HealthPoolName string = "health" HealthBindAddress string = "127.0.0.1:22333" )
View Source
const (
TwemproxyConfigFile = "/etc/twemproxy/nutcracker.yml"
)
Variables ¶
This section is empty.
Functions ¶
func AddTwemproxySidecar ¶
func AddTwemproxySidecar(podTemplateSpec corev1.PodTemplateSpec, twemproxySpec *saasv1alpha1.TwemproxySpec) corev1.PodTemplateSpec
func AddTwemproxyTaskSidecar ¶
func AddTwemproxyTaskSidecar(taskSpec pipelinev1beta1.TaskSpec, twemproxySpec *saasv1alpha1.TwemproxySpec) pipelinev1beta1.TaskSpec
func NewOptions ¶ added in v0.22.0
func NewOptions(spec saasv1alpha1.TwemproxySpec) *pod.Options
NewOptions generates the configuration for the Twemproxy sidecar
func TwemproxyContainer ¶
func TwemproxyContainer(twemproxySpec *saasv1alpha1.TwemproxySpec) corev1.Container
func TwemproxyContainerVolume ¶
func TwemproxyContainerVolume(twemproxySpec *saasv1alpha1.TwemproxySpec) corev1.Volume
Types ¶
type Server ¶
type Server struct { Address string Priority int Name string // contains filtered or unexported fields }
func (*Server) MarshalJSON ¶
func (*Server) UnmarshalJSON ¶
type ServerPoolConfig ¶
type ServerPoolConfig struct { Listen string `json:"listen"` Hash string `json:"hash,omitempty"` HashTag string `json:"hash_tag,omitempty"` Distribution string `json:"distribution,omitempty"` Timeout int `json:"timeout,omitempty"` Backlog int `json:"backlog,omitempty"` PreConnect bool `json:"preconnect"` Redis bool `json:"redis"` AutoEjectHosts bool `json:"auto_eject_hosts"` ServerFailureLimit int `json:"server_failure_limit,omitempty"` Servers []Server `json:"servers"` }
func GenerateServerPool ¶
func GenerateServerPool(pool saasv1alpha1.TwemproxyServerPool, targets map[string]Server) ServerPoolConfig
Click to show internal directories.
Click to hide internal directories.