Documentation
¶
Index ¶
- Variables
- type DeploymentClient
- func (dc *DeploymentClient) GetContainerResourceLimits(namespace string, name string) (float64, error)
- func (dc *DeploymentClient) GetKind() string
- func (dc *DeploymentClient) GetMaxReplicaFromAnnotation(namespace string, name string) (int, error)
- func (dc *DeploymentClient) GetObject(namespace string, name string) (client.Object, error)
- func (dc *DeploymentClient) GetObjectType() client.Object
- func (dc *DeploymentClient) GetReplicaCount(namespace string, name string) (int, error)
- func (dc *DeploymentClient) Scale(namespace string, name string, replicas int32) error
- type DeploymentClientRegistry
- type DeploymentClientRegistryBuilder
- func (cr *DeploymentClientRegistryBuilder) Build() *DeploymentClientRegistry
- func (cr *DeploymentClientRegistryBuilder) WithCustomDeploymentClient(client ObjectClient) *DeploymentClientRegistryBuilder
- func (cr *DeploymentClientRegistryBuilder) WithK8sClient(k8sClient client.Client) *DeploymentClientRegistryBuilder
- type ObjectClient
- type RolloutClient
- func (rc *RolloutClient) GetContainerResourceLimits(namespace string, name string) (float64, error)
- func (rc *RolloutClient) GetKind() string
- func (rc *RolloutClient) GetMaxReplicaFromAnnotation(namespace string, name string) (int, error)
- func (rc *RolloutClient) GetObject(namespace string, name string) (client.Object, error)
- func (rc *RolloutClient) GetObjectType() client.Object
- func (rc *RolloutClient) GetReplicaCount(namespace string, name string) (int, error)
- func (rc *RolloutClient) Scale(namespace string, name string, replicas int32) error
Constants ¶
This section is empty.
Variables ¶
View Source
var DeploymentGVK = schema.GroupVersionKind{
Group: "apps",
Version: "v1",
Kind: "Deployment",
}
View Source
var RolloutGVK = schema.GroupVersionKind{
Group: "argoproj.io",
Version: "v1alpha1",
Kind: "Rollout",
}
Functions ¶
This section is empty.
Types ¶
type DeploymentClient ¶
type DeploymentClient struct {
// contains filtered or unexported fields
}
func (*DeploymentClient) GetContainerResourceLimits ¶
func (dc *DeploymentClient) GetContainerResourceLimits(namespace string, name string) (float64, error)
func (*DeploymentClient) GetKind ¶
func (dc *DeploymentClient) GetKind() string
func (*DeploymentClient) GetMaxReplicaFromAnnotation ¶
func (dc *DeploymentClient) GetMaxReplicaFromAnnotation(namespace string, name string) (int, error)
func (*DeploymentClient) GetObjectType ¶
func (dc *DeploymentClient) GetObjectType() client.Object
func (*DeploymentClient) GetReplicaCount ¶
func (dc *DeploymentClient) GetReplicaCount(namespace string, name string) (int, error)
type DeploymentClientRegistry ¶
type DeploymentClientRegistry struct { Clients []ObjectClient // contains filtered or unexported fields }
func (*DeploymentClientRegistry) GetObjectClient ¶
func (cr *DeploymentClientRegistry) GetObjectClient(objectKind string) (ObjectClient, error)
type DeploymentClientRegistryBuilder ¶
type DeploymentClientRegistryBuilder DeploymentClientRegistry
func NewDeploymentClientRegistryBuilder ¶
func NewDeploymentClientRegistryBuilder() *DeploymentClientRegistryBuilder
func (*DeploymentClientRegistryBuilder) Build ¶
func (cr *DeploymentClientRegistryBuilder) Build() *DeploymentClientRegistry
func (*DeploymentClientRegistryBuilder) WithCustomDeploymentClient ¶
func (cr *DeploymentClientRegistryBuilder) WithCustomDeploymentClient(client ObjectClient) *DeploymentClientRegistryBuilder
func (*DeploymentClientRegistryBuilder) WithK8sClient ¶
func (cr *DeploymentClientRegistryBuilder) WithK8sClient(k8sClient client.Client) *DeploymentClientRegistryBuilder
type ObjectClient ¶
type ObjectClient interface { GetObject(namespace string, name string) (client.Object, error) GetObjectType() client.Object GetKind() string GetMaxReplicaFromAnnotation(namespace string, name string) (int, error) GetContainerResourceLimits(namespace string, name string) (float64, error) GetReplicaCount(namespace string, name string) (int, error) Scale(namespace string, name string, replicas int32) error }
func NewDeploymentClient ¶
func NewDeploymentClient(k8sClient client.Client) ObjectClient
func NewRolloutClient ¶
func NewRolloutClient(k8sClient client.Client) ObjectClient
type RolloutClient ¶
type RolloutClient struct {
// contains filtered or unexported fields
}
func (*RolloutClient) GetContainerResourceLimits ¶
func (rc *RolloutClient) GetContainerResourceLimits(namespace string, name string) (float64, error)
func (*RolloutClient) GetKind ¶
func (rc *RolloutClient) GetKind() string
func (*RolloutClient) GetMaxReplicaFromAnnotation ¶
func (rc *RolloutClient) GetMaxReplicaFromAnnotation(namespace string, name string) (int, error)
func (*RolloutClient) GetObjectType ¶
func (rc *RolloutClient) GetObjectType() client.Object
func (*RolloutClient) GetReplicaCount ¶
func (rc *RolloutClient) GetReplicaCount(namespace string, name string) (int, error)
Click to show internal directories.
Click to hide internal directories.