Documentation
¶
Index ¶
- Variables
- func GetDeploymentGlobalIdentifier(deployment *k8sAppsV1.Deployment) string
- func GetDeploymentIdentityPartition(deployment *k8sAppsV1.Deployment) string
- func GetDeploymentOriginalIdentifier(deployment *k8sAppsV1.Deployment) string
- func HandleAddUpdateDeployment(ctx context.Context, obj interface{}, d *DeploymentController) error
- func NewDeploymentCache() *deploymentCache
- type Controller
- type Delegator
- type DeploymentClusterEntry
- type DeploymentController
- func (d *DeploymentController) Added(ctx context.Context, obj interface{}) error
- func (d *DeploymentController) Deleted(ctx context.Context, obj interface{}) error
- func (d *DeploymentController) Get(ctx context.Context, isRetry bool, obj interface{}) (interface{}, error)
- func (d *DeploymentController) GetDeploymentBySelectorInNamespace(ctx context.Context, serviceSelector map[string]string, namespace string) []k8sAppsV1.Deployment
- func (d *DeploymentController) GetProcessItemStatus(obj interface{}) (string, error)
- func (d *DeploymentController) LogValueOfAdmiralIoIgnore(obj interface{})
- func (d *DeploymentController) UpdateProcessItemStatus(obj interface{}, status string) error
- func (d *DeploymentController) Updated(ctx context.Context, obj interface{}, oldObj interface{}) error
- type DeploymentHandler
- type DeploymentItem
- type EventType
- type InformerCacheObj
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // Log Formats ControllerLogFormat = monitoring.NewTaskFormatter("len=%v") LogQueueFormat = "op=" + operationInformerEvents + " " + monitoring.NewTaskFormatter("controller=%v cluster=%v len=%v") )
Functions ¶
func GetDeploymentGlobalIdentifier ¶
func GetDeploymentGlobalIdentifier(deployment *k8sAppsV1.Deployment) string
func GetDeploymentIdentityPartition ¶
func GetDeploymentIdentityPartition(deployment *k8sAppsV1.Deployment) string
func GetDeploymentOriginalIdentifier ¶
func GetDeploymentOriginalIdentifier(deployment *k8sAppsV1.Deployment) string
func HandleAddUpdateDeployment ¶
func HandleAddUpdateDeployment(ctx context.Context, obj interface{}, d *DeploymentController) error
func NewDeploymentCache ¶
func NewDeploymentCache() *deploymentCache
Types ¶
type Controller ¶
type Controller struct {
// contains filtered or unexported fields
}
func NewController ¶
func NewController(name, clusterEndpoint string, stopCh <-chan struct{}, delegator Delegator, informer cache.SharedIndexInformer) Controller
func (*Controller) Run ¶
func (c *Controller) Run(stopCh <-chan struct{})
Run starts the controller until it receives a message over stopCh
type Delegator ¶
type Delegator interface { Added(context.Context, interface{}) error Updated(context.Context, interface{}, interface{}) error Deleted(context.Context, interface{}) error UpdateProcessItemStatus(interface{}, string) error GetProcessItemStatus(interface{}) (string, error) LogValueOfAdmiralIoIgnore(interface{}) Get(ctx context.Context, isRetry bool, obj interface{}) (interface{}, error) }
Delegator interface contains the methods that are required
type DeploymentClusterEntry ¶
type DeploymentClusterEntry struct { Identity string Deployments map[string]*DeploymentItem }
type DeploymentController ¶
type DeploymentController struct { K8sClient kubernetes.Interface DeploymentHandler DeploymentHandler Cache *deploymentCache // contains filtered or unexported fields }
func NewDeploymentController ¶
func NewDeploymentController(stopCh <-chan struct{}, handler DeploymentHandler, config *rest.Config, resyncPeriod time.Duration, clientLoader client.ClientLoader) (*DeploymentController, error)
func (*DeploymentController) Added ¶
func (d *DeploymentController) Added(ctx context.Context, obj interface{}) error
func (*DeploymentController) Deleted ¶
func (d *DeploymentController) Deleted(ctx context.Context, obj interface{}) error
func (*DeploymentController) Get ¶
func (d *DeploymentController) Get(ctx context.Context, isRetry bool, obj interface{}) (interface{}, error)
func (*DeploymentController) GetDeploymentBySelectorInNamespace ¶
func (d *DeploymentController) GetDeploymentBySelectorInNamespace(ctx context.Context, serviceSelector map[string]string, namespace string) []k8sAppsV1.Deployment
func (*DeploymentController) GetProcessItemStatus ¶
func (d *DeploymentController) GetProcessItemStatus(obj interface{}) (string, error)
func (*DeploymentController) LogValueOfAdmiralIoIgnore ¶
func (d *DeploymentController) LogValueOfAdmiralIoIgnore(obj interface{})
func (*DeploymentController) UpdateProcessItemStatus ¶
func (d *DeploymentController) UpdateProcessItemStatus(obj interface{}, status string) error
type DeploymentHandler ¶
type DeploymentHandler interface { Added(ctx context.Context, obj *k8sAppsV1.Deployment) error Deleted(ctx context.Context, obj *k8sAppsV1.Deployment) error }
DeploymentHandler interface contains the methods that are required
type DeploymentItem ¶
type DeploymentItem struct { Deployment *k8sAppsV1.Deployment Status string }
type InformerCacheObj ¶
type InformerCacheObj struct {
// contains filtered or unexported fields
}
Click to show internal directories.
Click to hide internal directories.