Documentation
¶
Index ¶
- Variables
- func CheckKafka(conf CheckKafkaConfig) error
- func CheckMinIO(args CheckMinIOArgs) error
- func GetKafkaDialer(conf CheckKafkaConfig) (*kafka.Dialer, error)
- type CheckKafkaConfig
- type CheckMinIOArgs
- type ConditionGetter
- type PulsarConditionGetter
- type SSLConfig
- type SecretKeyRef
- type TCPDialConditionGetter
Constants ¶
This section is empty.
Variables ¶
View Source
var DependencyCheckTimeout = 5 * time.Second
View Source
var MQReadyCondition = v1beta1.MilvusCondition{ Type: v1beta1.MsgStreamReady, Status: corev1.ConditionTrue, Reason: v1beta1.ReasonMsgStreamReady, }
Functions ¶
func CheckKafka ¶
func CheckKafka(conf CheckKafkaConfig) error
func CheckMinIO ¶
func CheckMinIO(args CheckMinIOArgs) error
func GetKafkaDialer ¶
func GetKafkaDialer(conf CheckKafkaConfig) (*kafka.Dialer, error)
GetKafkaDialer returns a kafka.Dialer with TLS and SASL configured. Behavior:
- Protocol & mechanism are case-insensitive.
- PLAIN SASL does NOT hard-fail on empty creds (matches UT).
- SCRAM requires non-empty creds (will error otherwise).
Types ¶
type CheckKafkaConfig ¶
type CheckKafkaConfig struct {
SecretReader func(ns, name, key string) ([]byte, error) `json:"-"`
CACert []byte `json:"-"`
Namespace string `json:"-"` // CR namespace; used as fallback for Secret refs
BrokerList []string `json:"-"`
SecurityProtocol string `json:"securityProtocol"`
SASLMechanisms string `json:"saslMechanisms"`
SASLUsername string `json:"saslUsername,omitempty"` // fallback if Secret not set
SASLPassword string `json:"saslPassword,omitempty"` // fallback if Secret not set
SASLUsernameSecret *SecretKeyRef `json:"saslUsernameSecret,omitempty"`
SASLPasswordSecret *SecretKeyRef `json:"saslPasswordSecret,omitempty"`
SSL SSLConfig `json:"ssl,omitempty"`
}
func GetKafkaConfFromCR ¶
func GetKafkaConfFromCR(mc v1beta1.Milvus) (*CheckKafkaConfig, error)
GetKafkaConfFromCR get check kafka config from CR
type CheckMinIOArgs ¶
type CheckMinIOArgs struct {
// S3 / MinIO
Type string
AK string
SK string
Bucket string
Endpoint string
UseSSL bool
UseIAM bool
IAMEndpoint string
UseVirtualHost bool
// SSL Configuration
CACertificate []byte
InsecureSkipVerify bool
}
CheckMinIOArgs is info for acquiring storage condition
type ConditionGetter ¶
type ConditionGetter interface {
GetCondition() v1beta1.MilvusCondition
}
type PulsarConditionGetter ¶
type PulsarConditionGetter struct {
// contains filtered or unexported fields
}
func NewPulsarConditionGetter ¶
func NewPulsarConditionGetter(m *v1beta1.Milvus) *PulsarConditionGetter
func (PulsarConditionGetter) GetCondition ¶
func (p PulsarConditionGetter) GetCondition() v1beta1.MilvusCondition
type SSLConfig ¶ added in v1.3.11
type SSLConfig struct {
Enabled bool `json:"enabled"`
CACertSecret *SecretKeyRef `json:"caCertSecret,omitempty"`
CertSecret *SecretKeyRef `json:"certSecret,omitempty"` // optional: mTLS
KeySecret *SecretKeyRef `json:"keySecret,omitempty"` // optional: mTLS
KeyPasswordSecret *SecretKeyRef `json:"keyPasswordSecret,omitempty"` // optional
}
func (*SSLConfig) UnmarshalJSON ¶ added in v1.3.11
UnmarshalJSON accepts the bool and string forms supported by Milvus config.
type SecretKeyRef ¶ added in v1.3.11
type TCPDialConditionGetter ¶
type TCPDialConditionGetter struct {
// contains filtered or unexported fields
}
func NewTCPDialConditionGetter ¶
func NewTCPDialConditionGetter(conditionType v1beta1.MilvusConditionType, tcpAddrs []string) *TCPDialConditionGetter
func (*TCPDialConditionGetter) GetCondition ¶
func (s *TCPDialConditionGetter) GetCondition() v1beta1.MilvusCondition
Click to show internal directories.
Click to hide internal directories.