Documentation ¶
Index ¶
- type DefaultInterpreter
- func (e *DefaultInterpreter) AggregateStatus(object *unstructured.Unstructured, ...) (*unstructured.Unstructured, error)
- func (e *DefaultInterpreter) GetDependencies(object *unstructured.Unstructured) (dependencies []configv1alpha1.DependentObjectReference, err error)
- func (e *DefaultInterpreter) GetReplicas(object *unstructured.Unstructured) (int32, *workv1alpha2.ReplicaRequirements, error)
- func (e *DefaultInterpreter) HookEnabled(kind schema.GroupVersionKind, ...) bool
- func (e *DefaultInterpreter) InterpretHealth(object *unstructured.Unstructured) (bool, error)
- func (e *DefaultInterpreter) ReflectStatus(object *unstructured.Unstructured) (status *runtime.RawExtension, err error)
- func (e *DefaultInterpreter) Retain(desired *unstructured.Unstructured, observed *unstructured.Unstructured) (retained *unstructured.Unstructured, err error)
- func (e *DefaultInterpreter) ReviseReplica(object *unstructured.Unstructured, replica int64) (*unstructured.Unstructured, error)
- type FederatedGeneration
- type WrappedDaemonSetStatus
- type WrappedDeploymentStatus
- type WrappedStatefulSetStatus
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DefaultInterpreter ¶
type DefaultInterpreter struct {
// contains filtered or unexported fields
}
DefaultInterpreter contains all default operation interpreter factory for interpreting common resource.
func NewDefaultInterpreter ¶
func NewDefaultInterpreter() *DefaultInterpreter
NewDefaultInterpreter return a new DefaultInterpreter.
func (*DefaultInterpreter) AggregateStatus ¶
func (e *DefaultInterpreter) AggregateStatus(object *unstructured.Unstructured, aggregatedStatusItems []workv1alpha2.AggregatedStatusItem) (*unstructured.Unstructured, error)
AggregateStatus returns the objects that based on the 'object' but with status aggregated.
func (*DefaultInterpreter) GetDependencies ¶
func (e *DefaultInterpreter) GetDependencies(object *unstructured.Unstructured) (dependencies []configv1alpha1.DependentObjectReference, err error)
GetDependencies returns the dependent resources of the given object.
func (*DefaultInterpreter) GetReplicas ¶
func (e *DefaultInterpreter) GetReplicas(object *unstructured.Unstructured) (int32, *workv1alpha2.ReplicaRequirements, error)
GetReplicas returns the desired replicas of the object as well as the requirements of each replica.
func (*DefaultInterpreter) HookEnabled ¶
func (e *DefaultInterpreter) HookEnabled(kind schema.GroupVersionKind, operationType configv1alpha1.InterpreterOperation) bool
HookEnabled tells if any hook exist for specific resource type and operation type.
func (*DefaultInterpreter) InterpretHealth ¶
func (e *DefaultInterpreter) InterpretHealth(object *unstructured.Unstructured) (bool, error)
InterpretHealth returns the health state of the object.
func (*DefaultInterpreter) ReflectStatus ¶
func (e *DefaultInterpreter) ReflectStatus(object *unstructured.Unstructured) (status *runtime.RawExtension, err error)
ReflectStatus returns the status of the object.
func (*DefaultInterpreter) Retain ¶
func (e *DefaultInterpreter) Retain(desired *unstructured.Unstructured, observed *unstructured.Unstructured) (retained *unstructured.Unstructured, err error)
Retain returns the objects that based on the "desired" object but with values retained from the "observed" object.
func (*DefaultInterpreter) ReviseReplica ¶
func (e *DefaultInterpreter) ReviseReplica(object *unstructured.Unstructured, replica int64) (*unstructured.Unstructured, error)
ReviseReplica revises the replica of the given object.
type FederatedGeneration ¶ added in v1.11.0
type FederatedGeneration struct { // Generation holds the generation(.metadata.generation) of resource running on member cluster. Generation int64 `json:"generation,omitempty"` // ResourceTemplateGeneration holds the value of annotation resourcetemplate.karmada.io/generation grabbed // from resource running on member cluster. ResourceTemplateGeneration int64 `json:"resourceTemplateGeneration,omitempty"` }
FederatedGeneration holds the generation of the same resource in the member cluster and the Karmada control plane.
type WrappedDaemonSetStatus ¶ added in v1.11.0
type WrappedDaemonSetStatus struct { FederatedGeneration `json:",inline"` appsv1.DaemonSetStatus `json:",inline"` }
WrappedDaemonSetStatus is a wrapper for appsv1.DaemonSetStatus.
type WrappedDeploymentStatus ¶ added in v1.11.0
type WrappedDeploymentStatus struct { FederatedGeneration `json:",inline"` appsv1.DeploymentStatus `json:",inline"` }
WrappedDeploymentStatus is a wrapper for appsv1.DeploymentStatus.
type WrappedStatefulSetStatus ¶ added in v1.11.0
type WrappedStatefulSetStatus struct { FederatedGeneration `json:",inline"` appsv1.StatefulSetStatus `json:",inline"` }
WrappedStatefulSetStatus is a wrapper for appsv1.StatefulSetStatus.