remove out-dated files

Signed-off-by: Kevin Wang <kevinwzf0126@gmail.com>
This commit is contained in:
Kevin Wang 2021-01-25 10:43:54 +08:00 committed by Hongcai Ren
parent 4afcabe5f1
commit 203d52ac92
28 changed files with 0 additions and 3036 deletions

View File

@ -1,253 +0,0 @@
---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.4.1
creationTimestamp: null
name: overridepolicies.propagationstrategy.karmada.io
spec:
group: propagationstrategy.karmada.io
names:
kind: OverridePolicy
listKind: OverridePolicyList
plural: overridepolicies
singular: overridepolicy
scope: Namespaced
versions:
- name: v1alpha1
schema:
openAPIV3Schema:
description: OverridePolicy represents the policy that overrides a group of
resources to one or more clusters.
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation
of an object. Servers should convert recognized schemas to the latest
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
kind:
description: 'Kind is a string value representing the REST resource this
object represents. Servers may infer this from the endpoint the client
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
type: string
metadata:
type: object
spec:
description: Spec represents the desired behavior of OverridePolicy.
properties:
overriders:
description: Overriders represents the override rules that would apply
on resources
properties:
plaintext:
description: Plaintext represents override rules defined with
plaintext overriders.
items:
description: PlaintextOverrider is a simple overrider that overrides
target fields according to path, operator and value.
properties:
operator:
description: 'Operator indicates the operation on target
field. Available operators are: add, update and remove.'
enum:
- add
- remove
- replace
type: string
path:
description: Path indicates the path of target field
type: string
value:
description: Value to be applied to target field. Must be
empty when operator is Remove.
x-kubernetes-preserve-unknown-fields: true
required:
- operator
- path
type: object
type: array
type: object
resourceSelectors:
description: ResourceSelectors restricts resource types that this
override policy applies to.
items:
description: ResourceSelector the resources will be selected.
properties:
apiVersion:
description: APIVersion represents the API version of the target
resources.
type: string
kind:
description: Kind represents the Kind of the target resources.
type: string
labelSelector:
description: A label query over a set of resources. If name
is not empty, labelSelector will be ignored.
properties:
matchExpressions:
description: matchExpressions is a list of label selector
requirements. The requirements are ANDed.
items:
description: A label selector requirement is a selector
that contains values, a key, and an operator that relates
the key and values.
properties:
key:
description: key is the label key that the selector
applies to.
type: string
operator:
description: operator represents a key's relationship
to a set of values. Valid operators are In, NotIn,
Exists and DoesNotExist.
type: string
values:
description: values is an array of string values.
If the operator is In or NotIn, the values array
must be non-empty. If the operator is Exists or
DoesNotExist, the values array must be empty. This
array is replaced during a strategic merge patch.
items:
type: string
type: array
required:
- key
- operator
type: object
type: array
matchLabels:
additionalProperties:
type: string
description: matchLabels is a map of {key,value} pairs.
A single {key,value} in the matchLabels map is equivalent
to an element of matchExpressions, whose key field is
"key", the operator is "In", and the values array contains
only "value". The requirements are ANDed.
type: object
type: object
name:
description: Name of the target resource. Default is empty,
which means selecting all resources.
type: string
namespace:
description: Namespace of the target resource. Default is empty,
which means inherit from the parent object scope.
type: string
required:
- apiVersion
- kind
type: object
type: array
targetCluster:
description: TargetCluster defines restrictions on this override policy
that only applies to resources propagated to the matching clusters
properties:
clusterNames:
description: ClusterNames is the list of clusters to be selected.
items:
type: string
type: array
exclude:
description: ExcludedClusters is the list of clusters to be ignored.
items:
type: string
type: array
fieldSelector:
description: FieldSelector is a filter to select member clusters
by fields. If non-nil and non-empty, only the clusters match
this filter will be selected.
properties:
matchExpressions:
description: A list of field selector requirements.
items:
description: A node selector requirement is a selector that
contains values, a key, and an operator that relates the
key and values.
properties:
key:
description: The label key that the selector applies
to.
type: string
operator:
description: Represents a key's relationship to a set
of values. Valid operators are In, NotIn, Exists,
DoesNotExist. Gt, and Lt.
type: string
values:
description: An array of string values. If the operator
is In or NotIn, the values array must be non-empty.
If the operator is Exists or DoesNotExist, the values
array must be empty. If the operator is Gt or Lt,
the values array must have a single element, which
will be interpreted as an integer. This array is replaced
during a strategic merge patch.
items:
type: string
type: array
required:
- key
- operator
type: object
type: array
type: object
labelSelector:
description: LabelSelector is a filter to select member clusters
by labels. If non-nil and non-empty, only the clusters match
this filter will be selected.
properties:
matchExpressions:
description: matchExpressions is a list of label selector
requirements. The requirements are ANDed.
items:
description: A label selector requirement is a selector
that contains values, a key, and an operator that relates
the key and values.
properties:
key:
description: key is the label key that the selector
applies to.
type: string
operator:
description: operator represents a key's relationship
to a set of values. Valid operators are In, NotIn,
Exists and DoesNotExist.
type: string
values:
description: values is an array of string values. If
the operator is In or NotIn, the values array must
be non-empty. If the operator is Exists or DoesNotExist,
the values array must be empty. This array is replaced
during a strategic merge patch.
items:
type: string
type: array
required:
- key
- operator
type: object
type: array
matchLabels:
additionalProperties:
type: string
description: matchLabels is a map of {key,value} pairs. A
single {key,value} in the matchLabels map is equivalent
to an element of matchExpressions, whose key field is "key",
the operator is "In", and the values array contains only
"value". The requirements are ANDed.
type: object
type: object
type: object
type: object
required:
- spec
type: object
served: true
storage: true
status:
acceptedNames:
kind: ""
plural: ""
conditions: []
storedVersions: []

View File

@ -1,228 +0,0 @@
---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.4.1
creationTimestamp: null
name: propagationbindings.propagationstrategy.karmada.io
spec:
group: propagationstrategy.karmada.io
names:
kind: PropagationBinding
listKind: PropagationBindingList
plural: propagationbindings
singular: propagationbinding
scope: Namespaced
versions:
- name: v1alpha1
schema:
openAPIV3Schema:
description: PropagationBinding represents a binding of a kubernetes resource
with a propagation policy.
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation
of an object. Servers should convert recognized schemas to the latest
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
kind:
description: 'Kind is a string value representing the REST resource this
object represents. Servers may infer this from the endpoint the client
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
type: string
metadata:
type: object
spec:
description: Spec represents the desired behavior.
properties:
clusters:
description: Clusters represents target member clusters where the
resource to be deployed.
items:
description: TargetCluster represents the identifier of a member
cluster.
properties:
name:
description: Name of target cluster.
type: string
required:
- name
type: object
type: array
resource:
description: Resource represents the Kubernetes resource to be propagated.
properties:
apiVersion:
description: APIVersion represents the API version of the referent.
type: string
kind:
description: Kind represents the Kind of the referent.
type: string
name:
description: Name represents the name of the referent.
type: string
namespace:
description: Namespace represents the namespace for the referent.
For non-namespace scoped resources(e.g. 'ClusterRole')do not
need specify Namespace, and for namespace scoped resources,
Namespace is required. If Namespace is not specified, means
the resource is non-namespace scoped.
type: string
resourceVersion:
description: ResourceVersion represents the internal version of
the referenced object, that can be used by clients to determine
when object has changed.
type: string
required:
- apiVersion
- kind
- name
type: object
required:
- resource
type: object
status:
description: Status represents the most recently observed status of the
PropagationBinding.
properties:
aggregatedStatus:
description: AggregatedStatus represents status list of the resource
running in each member cluster.
items:
description: AggregatedStatusItem represents status of the resource
running in a member cluster.
properties:
clusterName:
description: ClusterName represents the member cluster name
which the resource deployed on.
type: string
resourceStatus:
description: ResourceStatus represents the status of the resource.
properties:
deploymentStatus:
description: Deployment represents the deployment status
in the member cluster, only available when the resource
kind is Deployment.
properties:
availableReplicas:
description: Total number of available pods (ready for
at least minReadySeconds) targeted by this deployment.
format: int32
type: integer
readyReplicas:
description: Total number of ready pods targeted by
this deployment.
format: int32
type: integer
replicas:
description: Total number of non-terminated pods targeted
by this deployment (their labels match the selector).
format: int32
type: integer
unavailableReplicas:
description: Total number of unavailable pods targeted
by this deployment. This is the total number of pods
that are still required for the deployment to have
100% available capacity. They may either be pods that
are running but not yet available or pods that still
have not been created.
format: int32
type: integer
updatedReplicas:
description: Total number of non-terminated pods targeted
by this deployment that have the desired template
spec.
format: int32
type: integer
type: object
type: object
required:
- clusterName
type: object
type: array
conditions:
description: Conditions contain the different condition statuses.
items:
description: "Condition contains details for one aspect of the current
state of this API Resource. --- This struct is intended for direct
use as an array at the field path .status.conditions. For example,
type FooStatus struct{ // Represents the observations of a
foo's current state. // Known .status.conditions.type are:
\"Available\", \"Progressing\", and \"Degraded\" // +patchMergeKey=type
\ // +patchStrategy=merge // +listType=map // +listMapKey=type
\ Conditions []metav1.Condition `json:\"conditions,omitempty\"
patchStrategy:\"merge\" patchMergeKey:\"type\" protobuf:\"bytes,1,rep,name=conditions\"`
\n // other fields }"
properties:
lastTransitionTime:
description: lastTransitionTime is the last time the condition
transitioned from one status to another. This should be when
the underlying condition changed. If that is not known, then
using the time when the API field changed is acceptable.
format: date-time
type: string
message:
description: message is a human readable message indicating
details about the transition. This may be an empty string.
maxLength: 32768
type: string
observedGeneration:
description: observedGeneration represents the .metadata.generation
that the condition was set based upon. For instance, if .metadata.generation
is currently 12, but the .status.conditions[x].observedGeneration
is 9, the condition is out of date with respect to the current
state of the instance.
format: int64
minimum: 0
type: integer
reason:
description: reason contains a programmatic identifier indicating
the reason for the condition's last transition. Producers
of specific condition types may define expected values and
meanings for this field, and whether the values are considered
a guaranteed API. The value should be a CamelCase string.
This field may not be empty.
maxLength: 1024
minLength: 1
pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$
type: string
status:
description: status of the condition, one of True, False, Unknown.
enum:
- "True"
- "False"
- Unknown
type: string
type:
description: type of condition in CamelCase or in foo.example.com/CamelCase.
--- Many .condition.type values are consistent across resources
like Available, but because arbitrary conditions can be useful
(see .node.status.conditions), the ability to deconflict is
important. The regex it matches is (dns1123SubdomainFmt/)?(qualifiedNameFmt)
maxLength: 316
pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$
type: string
required:
- lastTransitionTime
- message
- reason
- status
- type
type: object
type: array
type: object
required:
- spec
type: object
served: true
storage: true
subresources:
status: {}
status:
acceptedNames:
kind: ""
plural: ""
conditions: []
storedVersions: []

View File

@ -1,312 +0,0 @@
---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.4.1
creationTimestamp: null
name: propagationpolicies.propagationstrategy.karmada.io
spec:
group: propagationstrategy.karmada.io
names:
kind: PropagationPolicy
listKind: PropagationPolicyList
plural: propagationpolicies
singular: propagationpolicy
scope: Namespaced
versions:
- name: v1alpha1
schema:
openAPIV3Schema:
description: PropagationPolicy represents the policy that propagates a group
of resources to one or more clusters.
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation
of an object. Servers should convert recognized schemas to the latest
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
kind:
description: 'Kind is a string value representing the REST resource this
object represents. Servers may infer this from the endpoint the client
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
type: string
metadata:
type: object
spec:
description: Spec represents the desired behavior of PropagationPolicy.
properties:
association:
description: Association tells if relevant resources should be selected
automatically. e.g. a ConfigMap referred by a Deployment. default
false.
type: boolean
placement:
description: Placement represents the rule for select clusters to
propagate resources.
properties:
clusterAffinity:
description: ClusterAffinity represents scheduling restrictions
to a certain set of clusters. If not set, any cluster can be
scheduling candidate.
properties:
clusterNames:
description: ClusterNames is the list of clusters to be selected.
items:
type: string
type: array
exclude:
description: ExcludedClusters is the list of clusters to be
ignored.
items:
type: string
type: array
fieldSelector:
description: FieldSelector is a filter to select member clusters
by fields. If non-nil and non-empty, only the clusters match
this filter will be selected.
properties:
matchExpressions:
description: A list of field selector requirements.
items:
description: A node selector requirement is a selector
that contains values, a key, and an operator that
relates the key and values.
properties:
key:
description: The label key that the selector applies
to.
type: string
operator:
description: Represents a key's relationship to
a set of values. Valid operators are In, NotIn,
Exists, DoesNotExist. Gt, and Lt.
type: string
values:
description: An array of string values. If the operator
is In or NotIn, the values array must be non-empty.
If the operator is Exists or DoesNotExist, the
values array must be empty. If the operator is
Gt or Lt, the values array must have a single
element, which will be interpreted as an integer.
This array is replaced during a strategic merge
patch.
items:
type: string
type: array
required:
- key
- operator
type: object
type: array
type: object
labelSelector:
description: LabelSelector is a filter to select member clusters
by labels. If non-nil and non-empty, only the clusters match
this filter will be selected.
properties:
matchExpressions:
description: matchExpressions is a list of label selector
requirements. The requirements are ANDed.
items:
description: A label selector requirement is a selector
that contains values, a key, and an operator that
relates the key and values.
properties:
key:
description: key is the label key that the selector
applies to.
type: string
operator:
description: operator represents a key's relationship
to a set of values. Valid operators are In, NotIn,
Exists and DoesNotExist.
type: string
values:
description: values is an array of string values.
If the operator is In or NotIn, the values array
must be non-empty. If the operator is Exists or
DoesNotExist, the values array must be empty.
This array is replaced during a strategic merge
patch.
items:
type: string
type: array
required:
- key
- operator
type: object
type: array
matchLabels:
additionalProperties:
type: string
description: matchLabels is a map of {key,value} pairs.
A single {key,value} in the matchLabels map is equivalent
to an element of matchExpressions, whose key field is
"key", the operator is "In", and the values array contains
only "value". The requirements are ANDed.
type: object
type: object
type: object
clusterTolerations:
description: ClusterTolerations represents the tolerations.
items:
description: The pod this Toleration is attached to tolerates
any taint that matches the triple <key,value,effect> using
the matching operator <operator>.
properties:
effect:
description: Effect indicates the taint effect to match.
Empty means match all taint effects. When specified, allowed
values are NoSchedule, PreferNoSchedule and NoExecute.
type: string
key:
description: Key is the taint key that the toleration applies
to. Empty means match all taint keys. If the key is empty,
operator must be Exists; this combination means to match
all values and all keys.
type: string
operator:
description: Operator represents a key's relationship to
the value. Valid operators are Exists and Equal. Defaults
to Equal. Exists is equivalent to wildcard for value,
so that a pod can tolerate all taints of a particular
category.
type: string
tolerationSeconds:
description: TolerationSeconds represents the period of
time the toleration (which must be of effect NoExecute,
otherwise this field is ignored) tolerates the taint.
By default, it is not set, which means tolerate the taint
forever (do not evict). Zero and negative values will
be treated as 0 (evict immediately) by the system.
format: int64
type: integer
value:
description: Value is the taint value the toleration matches
to. If the operator is Exists, the value should be empty,
otherwise just a regular string.
type: string
type: object
type: array
spreadConstraints:
description: SpreadConstraints represents a list of the scheduling
constraints.
items:
description: SpreadConstraint represents the spread constraints
on resources.
properties:
maximum:
description: Maximum restricts the maximum number of cluster
units to be selected.
type: integer
minimum:
description: Minimum restricts the minimum number of cluster
units to be selected.
type: integer
spreadByField:
description: 'SpreadByField represents the field used for
grouping member clusters into units. Resources will be
spread among different cluster units. Available field
for spreading are: region, zone, cluster and provider.'
type: string
spreadByLabel:
description: SpreadByLabel represents the label key used
for grouping member clusters into units. Resources will
be spread among different cluster units.
type: string
type: object
type: array
type: object
resourceSelectors:
description: ResourceSelectors used to select resources. nil represents
all resources.
items:
description: ResourceSelector the resources will be selected.
properties:
apiVersion:
description: APIVersion represents the API version of the target
resources.
type: string
kind:
description: Kind represents the Kind of the target resources.
type: string
labelSelector:
description: A label query over a set of resources. If name
is not empty, labelSelector will be ignored.
properties:
matchExpressions:
description: matchExpressions is a list of label selector
requirements. The requirements are ANDed.
items:
description: A label selector requirement is a selector
that contains values, a key, and an operator that relates
the key and values.
properties:
key:
description: key is the label key that the selector
applies to.
type: string
operator:
description: operator represents a key's relationship
to a set of values. Valid operators are In, NotIn,
Exists and DoesNotExist.
type: string
values:
description: values is an array of string values.
If the operator is In or NotIn, the values array
must be non-empty. If the operator is Exists or
DoesNotExist, the values array must be empty. This
array is replaced during a strategic merge patch.
items:
type: string
type: array
required:
- key
- operator
type: object
type: array
matchLabels:
additionalProperties:
type: string
description: matchLabels is a map of {key,value} pairs.
A single {key,value} in the matchLabels map is equivalent
to an element of matchExpressions, whose key field is
"key", the operator is "In", and the values array contains
only "value". The requirements are ANDed.
type: object
type: object
name:
description: Name of the target resource. Default is empty,
which means selecting all resources.
type: string
namespace:
description: Namespace of the target resource. Default is empty,
which means inherit from the parent object scope.
type: string
required:
- apiVersion
- kind
type: object
type: array
schedulerName:
description: SchedulerName represents which scheduler to proceed the
scheduling. If specified, the policy will be dispatched by specified
scheduler. If not specified, the policy will be dispatched by default
scheduler.
type: string
type: object
required:
- spec
type: object
served: true
storage: true
subresources:
status: {}
status:
acceptedNames:
kind: ""
plural: ""
conditions: []
storedVersions: []

View File

@ -1,195 +0,0 @@
---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.4.1
creationTimestamp: null
name: propagationworks.propagationstrategy.karmada.io
spec:
group: propagationstrategy.karmada.io
names:
kind: PropagationWork
listKind: PropagationWorkList
plural: propagationworks
singular: propagationwork
scope: Namespaced
versions:
- name: v1alpha1
schema:
openAPIV3Schema:
description: PropagationWork defines a list of resources to be deployed on
the member cluster.
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation
of an object. Servers should convert recognized schemas to the latest
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
kind:
description: 'Kind is a string value representing the REST resource this
object represents. Servers may infer this from the endpoint the client
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
type: string
metadata:
type: object
spec:
description: Spec represents the desired behavior of PropagationWork.
properties:
workload:
description: Workload represents the manifest workload to be deployed
on managed cluster.
properties:
manifests:
description: Manifests represents a list of Kubernetes resources
to be deployed on the managed cluster.
items:
description: Manifest represents a resource to be deployed on
managed cluster.
type: object
x-kubernetes-preserve-unknown-fields: true
type: array
type: object
type: object
status:
description: Status represents the status of PropagationStatus.
properties:
conditions:
description: 'Conditions contain the different condition statuses
for this work. Valid condition types are: 1. Applied represents
workload in PropagationWork is applied successfully on a managed
cluster. 2. Progressing represents workload in PropagationWork is
being applied on a managed cluster. 3. Available represents workload
in PropagationWork exists on the managed cluster. 4. Degraded represents
the current state of workload does not match the desired state for
a certain period.'
items:
description: "Condition contains details for one aspect of the current
state of this API Resource. --- This struct is intended for direct
use as an array at the field path .status.conditions. For example,
type FooStatus struct{ // Represents the observations of a
foo's current state. // Known .status.conditions.type are:
\"Available\", \"Progressing\", and \"Degraded\" // +patchMergeKey=type
\ // +patchStrategy=merge // +listType=map // +listMapKey=type
\ Conditions []metav1.Condition `json:\"conditions,omitempty\"
patchStrategy:\"merge\" patchMergeKey:\"type\" protobuf:\"bytes,1,rep,name=conditions\"`
\n // other fields }"
properties:
lastTransitionTime:
description: lastTransitionTime is the last time the condition
transitioned from one status to another. This should be when
the underlying condition changed. If that is not known, then
using the time when the API field changed is acceptable.
format: date-time
type: string
message:
description: message is a human readable message indicating
details about the transition. This may be an empty string.
maxLength: 32768
type: string
observedGeneration:
description: observedGeneration represents the .metadata.generation
that the condition was set based upon. For instance, if .metadata.generation
is currently 12, but the .status.conditions[x].observedGeneration
is 9, the condition is out of date with respect to the current
state of the instance.
format: int64
minimum: 0
type: integer
reason:
description: reason contains a programmatic identifier indicating
the reason for the condition's last transition. Producers
of specific condition types may define expected values and
meanings for this field, and whether the values are considered
a guaranteed API. The value should be a CamelCase string.
This field may not be empty.
maxLength: 1024
minLength: 1
pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$
type: string
status:
description: status of the condition, one of True, False, Unknown.
enum:
- "True"
- "False"
- Unknown
type: string
type:
description: type of condition in CamelCase or in foo.example.com/CamelCase.
--- Many .condition.type values are consistent across resources
like Available, but because arbitrary conditions can be useful
(see .node.status.conditions), the ability to deconflict is
important. The regex it matches is (dns1123SubdomainFmt/)?(qualifiedNameFmt)
maxLength: 316
pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$
type: string
required:
- lastTransitionTime
- message
- reason
- status
- type
type: object
type: array
manifestStatuses:
description: ManifestStatuses contains running status of manifests
in spec.
items:
description: ManifestStatus contains running status of a specific
manifest in spec.
properties:
identifier:
description: Identifier represents the identity of a resource
linking to manifests in spec.
properties:
group:
description: Group is the group of the resource.
type: string
kind:
description: Kind is the kind of the resource.
type: string
name:
description: Name is the name of the resource
type: string
namespace:
description: Namespace is the namespace of the resource,
the resource is cluster scoped if the value is empty
type: string
ordinal:
description: Ordinal represents an index in manifests list,
so the condition can still be linked to a manifest even
though manifest cannot be parsed successfully.
type: integer
resource:
description: Resource is the resource type of the resource
type: string
version:
description: Version is the version of the resource.
type: string
required:
- kind
- name
- ordinal
- resource
- version
type: object
required:
- identifier
type: object
x-kubernetes-preserve-unknown-fields: true
type: array
type: object
required:
- spec
type: object
served: true
storage: true
subresources:
status: {}
status:
acceptedNames:
kind: ""
plural: ""
conditions: []
storedVersions: []

View File

@ -1,4 +0,0 @@
// Code generated by client-gen. DO NOT EDIT.
// This package has the automatically generated typed clients.
package v1alpha1

View File

@ -1,4 +0,0 @@
// Code generated by client-gen. DO NOT EDIT.
// Package fake has the automatically generated clients.
package fake

View File

@ -1,114 +0,0 @@
// Code generated by client-gen. DO NOT EDIT.
package fake
import (
"context"
v1alpha1 "github.com/karmada-io/karmada/pkg/apis/propagationstrategy/v1alpha1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
watch "k8s.io/apimachinery/pkg/watch"
testing "k8s.io/client-go/testing"
)
// FakeOverridePolicies implements OverridePolicyInterface
type FakeOverridePolicies struct {
Fake *FakePropagationstrategyV1alpha1
ns string
}
var overridepoliciesResource = schema.GroupVersionResource{Group: "propagationstrategy.karmada.io", Version: "v1alpha1", Resource: "overridepolicies"}
var overridepoliciesKind = schema.GroupVersionKind{Group: "propagationstrategy.karmada.io", Version: "v1alpha1", Kind: "OverridePolicy"}
// Get takes name of the overridePolicy, and returns the corresponding overridePolicy object, and an error if there is any.
func (c *FakeOverridePolicies) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha1.OverridePolicy, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(overridepoliciesResource, c.ns, name), &v1alpha1.OverridePolicy{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.OverridePolicy), err
}
// List takes label and field selectors, and returns the list of OverridePolicies that match those selectors.
func (c *FakeOverridePolicies) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha1.OverridePolicyList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(overridepoliciesResource, overridepoliciesKind, c.ns, opts), &v1alpha1.OverridePolicyList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1alpha1.OverridePolicyList{ListMeta: obj.(*v1alpha1.OverridePolicyList).ListMeta}
for _, item := range obj.(*v1alpha1.OverridePolicyList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested overridePolicies.
func (c *FakeOverridePolicies) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(overridepoliciesResource, c.ns, opts))
}
// Create takes the representation of a overridePolicy and creates it. Returns the server's representation of the overridePolicy, and an error, if there is any.
func (c *FakeOverridePolicies) Create(ctx context.Context, overridePolicy *v1alpha1.OverridePolicy, opts v1.CreateOptions) (result *v1alpha1.OverridePolicy, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(overridepoliciesResource, c.ns, overridePolicy), &v1alpha1.OverridePolicy{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.OverridePolicy), err
}
// Update takes the representation of a overridePolicy and updates it. Returns the server's representation of the overridePolicy, and an error, if there is any.
func (c *FakeOverridePolicies) Update(ctx context.Context, overridePolicy *v1alpha1.OverridePolicy, opts v1.UpdateOptions) (result *v1alpha1.OverridePolicy, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(overridepoliciesResource, c.ns, overridePolicy), &v1alpha1.OverridePolicy{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.OverridePolicy), err
}
// Delete takes name of the overridePolicy and deletes it. Returns an error if one occurs.
func (c *FakeOverridePolicies) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(overridepoliciesResource, c.ns, name), &v1alpha1.OverridePolicy{})
return err
}
// DeleteCollection deletes a collection of objects.
func (c *FakeOverridePolicies) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(overridepoliciesResource, c.ns, listOpts)
_, err := c.Fake.Invokes(action, &v1alpha1.OverridePolicyList{})
return err
}
// Patch applies the patch and returns the patched overridePolicy.
func (c *FakeOverridePolicies) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.OverridePolicy, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(overridepoliciesResource, c.ns, name, pt, data, subresources...), &v1alpha1.OverridePolicy{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.OverridePolicy), err
}

View File

@ -1,126 +0,0 @@
// Code generated by client-gen. DO NOT EDIT.
package fake
import (
"context"
v1alpha1 "github.com/karmada-io/karmada/pkg/apis/propagationstrategy/v1alpha1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
watch "k8s.io/apimachinery/pkg/watch"
testing "k8s.io/client-go/testing"
)
// FakePropagationBindings implements PropagationBindingInterface
type FakePropagationBindings struct {
Fake *FakePropagationstrategyV1alpha1
ns string
}
var propagationbindingsResource = schema.GroupVersionResource{Group: "propagationstrategy.karmada.io", Version: "v1alpha1", Resource: "propagationbindings"}
var propagationbindingsKind = schema.GroupVersionKind{Group: "propagationstrategy.karmada.io", Version: "v1alpha1", Kind: "PropagationBinding"}
// Get takes name of the propagationBinding, and returns the corresponding propagationBinding object, and an error if there is any.
func (c *FakePropagationBindings) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha1.PropagationBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(propagationbindingsResource, c.ns, name), &v1alpha1.PropagationBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.PropagationBinding), err
}
// List takes label and field selectors, and returns the list of PropagationBindings that match those selectors.
func (c *FakePropagationBindings) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha1.PropagationBindingList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(propagationbindingsResource, propagationbindingsKind, c.ns, opts), &v1alpha1.PropagationBindingList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1alpha1.PropagationBindingList{ListMeta: obj.(*v1alpha1.PropagationBindingList).ListMeta}
for _, item := range obj.(*v1alpha1.PropagationBindingList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested propagationBindings.
func (c *FakePropagationBindings) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(propagationbindingsResource, c.ns, opts))
}
// Create takes the representation of a propagationBinding and creates it. Returns the server's representation of the propagationBinding, and an error, if there is any.
func (c *FakePropagationBindings) Create(ctx context.Context, propagationBinding *v1alpha1.PropagationBinding, opts v1.CreateOptions) (result *v1alpha1.PropagationBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(propagationbindingsResource, c.ns, propagationBinding), &v1alpha1.PropagationBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.PropagationBinding), err
}
// Update takes the representation of a propagationBinding and updates it. Returns the server's representation of the propagationBinding, and an error, if there is any.
func (c *FakePropagationBindings) Update(ctx context.Context, propagationBinding *v1alpha1.PropagationBinding, opts v1.UpdateOptions) (result *v1alpha1.PropagationBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(propagationbindingsResource, c.ns, propagationBinding), &v1alpha1.PropagationBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.PropagationBinding), err
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *FakePropagationBindings) UpdateStatus(ctx context.Context, propagationBinding *v1alpha1.PropagationBinding, opts v1.UpdateOptions) (*v1alpha1.PropagationBinding, error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateSubresourceAction(propagationbindingsResource, "status", c.ns, propagationBinding), &v1alpha1.PropagationBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.PropagationBinding), err
}
// Delete takes name of the propagationBinding and deletes it. Returns an error if one occurs.
func (c *FakePropagationBindings) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(propagationbindingsResource, c.ns, name), &v1alpha1.PropagationBinding{})
return err
}
// DeleteCollection deletes a collection of objects.
func (c *FakePropagationBindings) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(propagationbindingsResource, c.ns, listOpts)
_, err := c.Fake.Invokes(action, &v1alpha1.PropagationBindingList{})
return err
}
// Patch applies the patch and returns the patched propagationBinding.
func (c *FakePropagationBindings) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.PropagationBinding, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(propagationbindingsResource, c.ns, name, pt, data, subresources...), &v1alpha1.PropagationBinding{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.PropagationBinding), err
}

View File

@ -1,114 +0,0 @@
// Code generated by client-gen. DO NOT EDIT.
package fake
import (
"context"
v1alpha1 "github.com/karmada-io/karmada/pkg/apis/propagationstrategy/v1alpha1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
watch "k8s.io/apimachinery/pkg/watch"
testing "k8s.io/client-go/testing"
)
// FakePropagationPolicies implements PropagationPolicyInterface
type FakePropagationPolicies struct {
Fake *FakePropagationstrategyV1alpha1
ns string
}
var propagationpoliciesResource = schema.GroupVersionResource{Group: "propagationstrategy.karmada.io", Version: "v1alpha1", Resource: "propagationpolicies"}
var propagationpoliciesKind = schema.GroupVersionKind{Group: "propagationstrategy.karmada.io", Version: "v1alpha1", Kind: "PropagationPolicy"}
// Get takes name of the propagationPolicy, and returns the corresponding propagationPolicy object, and an error if there is any.
func (c *FakePropagationPolicies) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha1.PropagationPolicy, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(propagationpoliciesResource, c.ns, name), &v1alpha1.PropagationPolicy{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.PropagationPolicy), err
}
// List takes label and field selectors, and returns the list of PropagationPolicies that match those selectors.
func (c *FakePropagationPolicies) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha1.PropagationPolicyList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(propagationpoliciesResource, propagationpoliciesKind, c.ns, opts), &v1alpha1.PropagationPolicyList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1alpha1.PropagationPolicyList{ListMeta: obj.(*v1alpha1.PropagationPolicyList).ListMeta}
for _, item := range obj.(*v1alpha1.PropagationPolicyList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested propagationPolicies.
func (c *FakePropagationPolicies) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(propagationpoliciesResource, c.ns, opts))
}
// Create takes the representation of a propagationPolicy and creates it. Returns the server's representation of the propagationPolicy, and an error, if there is any.
func (c *FakePropagationPolicies) Create(ctx context.Context, propagationPolicy *v1alpha1.PropagationPolicy, opts v1.CreateOptions) (result *v1alpha1.PropagationPolicy, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(propagationpoliciesResource, c.ns, propagationPolicy), &v1alpha1.PropagationPolicy{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.PropagationPolicy), err
}
// Update takes the representation of a propagationPolicy and updates it. Returns the server's representation of the propagationPolicy, and an error, if there is any.
func (c *FakePropagationPolicies) Update(ctx context.Context, propagationPolicy *v1alpha1.PropagationPolicy, opts v1.UpdateOptions) (result *v1alpha1.PropagationPolicy, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(propagationpoliciesResource, c.ns, propagationPolicy), &v1alpha1.PropagationPolicy{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.PropagationPolicy), err
}
// Delete takes name of the propagationPolicy and deletes it. Returns an error if one occurs.
func (c *FakePropagationPolicies) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(propagationpoliciesResource, c.ns, name), &v1alpha1.PropagationPolicy{})
return err
}
// DeleteCollection deletes a collection of objects.
func (c *FakePropagationPolicies) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(propagationpoliciesResource, c.ns, listOpts)
_, err := c.Fake.Invokes(action, &v1alpha1.PropagationPolicyList{})
return err
}
// Patch applies the patch and returns the patched propagationPolicy.
func (c *FakePropagationPolicies) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.PropagationPolicy, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(propagationpoliciesResource, c.ns, name, pt, data, subresources...), &v1alpha1.PropagationPolicy{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.PropagationPolicy), err
}

View File

@ -1,36 +0,0 @@
// Code generated by client-gen. DO NOT EDIT.
package fake
import (
v1alpha1 "github.com/karmada-io/karmada/pkg/generated/clientset/versioned/typed/propagationstrategy/v1alpha1"
rest "k8s.io/client-go/rest"
testing "k8s.io/client-go/testing"
)
type FakePropagationstrategyV1alpha1 struct {
*testing.Fake
}
func (c *FakePropagationstrategyV1alpha1) OverridePolicies(namespace string) v1alpha1.OverridePolicyInterface {
return &FakeOverridePolicies{c, namespace}
}
func (c *FakePropagationstrategyV1alpha1) PropagationBindings(namespace string) v1alpha1.PropagationBindingInterface {
return &FakePropagationBindings{c, namespace}
}
func (c *FakePropagationstrategyV1alpha1) PropagationPolicies(namespace string) v1alpha1.PropagationPolicyInterface {
return &FakePropagationPolicies{c, namespace}
}
func (c *FakePropagationstrategyV1alpha1) PropagationWorks(namespace string) v1alpha1.PropagationWorkInterface {
return &FakePropagationWorks{c, namespace}
}
// RESTClient returns a RESTClient that is used to communicate
// with API server by this client implementation.
func (c *FakePropagationstrategyV1alpha1) RESTClient() rest.Interface {
var ret *rest.RESTClient
return ret
}

View File

@ -1,126 +0,0 @@
// Code generated by client-gen. DO NOT EDIT.
package fake
import (
"context"
v1alpha1 "github.com/karmada-io/karmada/pkg/apis/propagationstrategy/v1alpha1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
watch "k8s.io/apimachinery/pkg/watch"
testing "k8s.io/client-go/testing"
)
// FakePropagationWorks implements PropagationWorkInterface
type FakePropagationWorks struct {
Fake *FakePropagationstrategyV1alpha1
ns string
}
var propagationworksResource = schema.GroupVersionResource{Group: "propagationstrategy.karmada.io", Version: "v1alpha1", Resource: "propagationworks"}
var propagationworksKind = schema.GroupVersionKind{Group: "propagationstrategy.karmada.io", Version: "v1alpha1", Kind: "PropagationWork"}
// Get takes name of the propagationWork, and returns the corresponding propagationWork object, and an error if there is any.
func (c *FakePropagationWorks) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha1.PropagationWork, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(propagationworksResource, c.ns, name), &v1alpha1.PropagationWork{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.PropagationWork), err
}
// List takes label and field selectors, and returns the list of PropagationWorks that match those selectors.
func (c *FakePropagationWorks) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha1.PropagationWorkList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(propagationworksResource, propagationworksKind, c.ns, opts), &v1alpha1.PropagationWorkList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1alpha1.PropagationWorkList{ListMeta: obj.(*v1alpha1.PropagationWorkList).ListMeta}
for _, item := range obj.(*v1alpha1.PropagationWorkList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested propagationWorks.
func (c *FakePropagationWorks) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(propagationworksResource, c.ns, opts))
}
// Create takes the representation of a propagationWork and creates it. Returns the server's representation of the propagationWork, and an error, if there is any.
func (c *FakePropagationWorks) Create(ctx context.Context, propagationWork *v1alpha1.PropagationWork, opts v1.CreateOptions) (result *v1alpha1.PropagationWork, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(propagationworksResource, c.ns, propagationWork), &v1alpha1.PropagationWork{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.PropagationWork), err
}
// Update takes the representation of a propagationWork and updates it. Returns the server's representation of the propagationWork, and an error, if there is any.
func (c *FakePropagationWorks) Update(ctx context.Context, propagationWork *v1alpha1.PropagationWork, opts v1.UpdateOptions) (result *v1alpha1.PropagationWork, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(propagationworksResource, c.ns, propagationWork), &v1alpha1.PropagationWork{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.PropagationWork), err
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *FakePropagationWorks) UpdateStatus(ctx context.Context, propagationWork *v1alpha1.PropagationWork, opts v1.UpdateOptions) (*v1alpha1.PropagationWork, error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateSubresourceAction(propagationworksResource, "status", c.ns, propagationWork), &v1alpha1.PropagationWork{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.PropagationWork), err
}
// Delete takes name of the propagationWork and deletes it. Returns an error if one occurs.
func (c *FakePropagationWorks) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(propagationworksResource, c.ns, name), &v1alpha1.PropagationWork{})
return err
}
// DeleteCollection deletes a collection of objects.
func (c *FakePropagationWorks) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(propagationworksResource, c.ns, listOpts)
_, err := c.Fake.Invokes(action, &v1alpha1.PropagationWorkList{})
return err
}
// Patch applies the patch and returns the patched propagationWork.
func (c *FakePropagationWorks) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.PropagationWork, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(propagationworksResource, c.ns, name, pt, data, subresources...), &v1alpha1.PropagationWork{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.PropagationWork), err
}

View File

@ -1,11 +0,0 @@
// Code generated by client-gen. DO NOT EDIT.
package v1alpha1
type OverridePolicyExpansion interface{}
type PropagationBindingExpansion interface{}
type PropagationPolicyExpansion interface{}
type PropagationWorkExpansion interface{}

View File

@ -1,162 +0,0 @@
// Code generated by client-gen. DO NOT EDIT.
package v1alpha1
import (
"context"
"time"
v1alpha1 "github.com/karmada-io/karmada/pkg/apis/propagationstrategy/v1alpha1"
scheme "github.com/karmada-io/karmada/pkg/generated/clientset/versioned/scheme"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
types "k8s.io/apimachinery/pkg/types"
watch "k8s.io/apimachinery/pkg/watch"
rest "k8s.io/client-go/rest"
)
// OverridePoliciesGetter has a method to return a OverridePolicyInterface.
// A group's client should implement this interface.
type OverridePoliciesGetter interface {
OverridePolicies(namespace string) OverridePolicyInterface
}
// OverridePolicyInterface has methods to work with OverridePolicy resources.
type OverridePolicyInterface interface {
Create(ctx context.Context, overridePolicy *v1alpha1.OverridePolicy, opts v1.CreateOptions) (*v1alpha1.OverridePolicy, error)
Update(ctx context.Context, overridePolicy *v1alpha1.OverridePolicy, opts v1.UpdateOptions) (*v1alpha1.OverridePolicy, error)
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha1.OverridePolicy, error)
List(ctx context.Context, opts v1.ListOptions) (*v1alpha1.OverridePolicyList, error)
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.OverridePolicy, err error)
OverridePolicyExpansion
}
// overridePolicies implements OverridePolicyInterface
type overridePolicies struct {
client rest.Interface
ns string
}
// newOverridePolicies returns a OverridePolicies
func newOverridePolicies(c *PropagationstrategyV1alpha1Client, namespace string) *overridePolicies {
return &overridePolicies{
client: c.RESTClient(),
ns: namespace,
}
}
// Get takes name of the overridePolicy, and returns the corresponding overridePolicy object, and an error if there is any.
func (c *overridePolicies) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha1.OverridePolicy, err error) {
result = &v1alpha1.OverridePolicy{}
err = c.client.Get().
Namespace(c.ns).
Resource("overridepolicies").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do(ctx).
Into(result)
return
}
// List takes label and field selectors, and returns the list of OverridePolicies that match those selectors.
func (c *overridePolicies) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha1.OverridePolicyList, err error) {
var timeout time.Duration
if opts.TimeoutSeconds != nil {
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
}
result = &v1alpha1.OverridePolicyList{}
err = c.client.Get().
Namespace(c.ns).
Resource("overridepolicies").
VersionedParams(&opts, scheme.ParameterCodec).
Timeout(timeout).
Do(ctx).
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested overridePolicies.
func (c *overridePolicies) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
var timeout time.Duration
if opts.TimeoutSeconds != nil {
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
}
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("overridepolicies").
VersionedParams(&opts, scheme.ParameterCodec).
Timeout(timeout).
Watch(ctx)
}
// Create takes the representation of a overridePolicy and creates it. Returns the server's representation of the overridePolicy, and an error, if there is any.
func (c *overridePolicies) Create(ctx context.Context, overridePolicy *v1alpha1.OverridePolicy, opts v1.CreateOptions) (result *v1alpha1.OverridePolicy, err error) {
result = &v1alpha1.OverridePolicy{}
err = c.client.Post().
Namespace(c.ns).
Resource("overridepolicies").
VersionedParams(&opts, scheme.ParameterCodec).
Body(overridePolicy).
Do(ctx).
Into(result)
return
}
// Update takes the representation of a overridePolicy and updates it. Returns the server's representation of the overridePolicy, and an error, if there is any.
func (c *overridePolicies) Update(ctx context.Context, overridePolicy *v1alpha1.OverridePolicy, opts v1.UpdateOptions) (result *v1alpha1.OverridePolicy, err error) {
result = &v1alpha1.OverridePolicy{}
err = c.client.Put().
Namespace(c.ns).
Resource("overridepolicies").
Name(overridePolicy.Name).
VersionedParams(&opts, scheme.ParameterCodec).
Body(overridePolicy).
Do(ctx).
Into(result)
return
}
// Delete takes name of the overridePolicy and deletes it. Returns an error if one occurs.
func (c *overridePolicies) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
return c.client.Delete().
Namespace(c.ns).
Resource("overridepolicies").
Name(name).
Body(&opts).
Do(ctx).
Error()
}
// DeleteCollection deletes a collection of objects.
func (c *overridePolicies) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
var timeout time.Duration
if listOpts.TimeoutSeconds != nil {
timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second
}
return c.client.Delete().
Namespace(c.ns).
Resource("overridepolicies").
VersionedParams(&listOpts, scheme.ParameterCodec).
Timeout(timeout).
Body(&opts).
Do(ctx).
Error()
}
// Patch applies the patch and returns the patched overridePolicy.
func (c *overridePolicies) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.OverridePolicy, err error) {
result = &v1alpha1.OverridePolicy{}
err = c.client.Patch(pt).
Namespace(c.ns).
Resource("overridepolicies").
Name(name).
SubResource(subresources...).
VersionedParams(&opts, scheme.ParameterCodec).
Body(data).
Do(ctx).
Into(result)
return
}

View File

@ -1,179 +0,0 @@
// Code generated by client-gen. DO NOT EDIT.
package v1alpha1
import (
"context"
"time"
v1alpha1 "github.com/karmada-io/karmada/pkg/apis/propagationstrategy/v1alpha1"
scheme "github.com/karmada-io/karmada/pkg/generated/clientset/versioned/scheme"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
types "k8s.io/apimachinery/pkg/types"
watch "k8s.io/apimachinery/pkg/watch"
rest "k8s.io/client-go/rest"
)
// PropagationBindingsGetter has a method to return a PropagationBindingInterface.
// A group's client should implement this interface.
type PropagationBindingsGetter interface {
PropagationBindings(namespace string) PropagationBindingInterface
}
// PropagationBindingInterface has methods to work with PropagationBinding resources.
type PropagationBindingInterface interface {
Create(ctx context.Context, propagationBinding *v1alpha1.PropagationBinding, opts v1.CreateOptions) (*v1alpha1.PropagationBinding, error)
Update(ctx context.Context, propagationBinding *v1alpha1.PropagationBinding, opts v1.UpdateOptions) (*v1alpha1.PropagationBinding, error)
UpdateStatus(ctx context.Context, propagationBinding *v1alpha1.PropagationBinding, opts v1.UpdateOptions) (*v1alpha1.PropagationBinding, error)
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha1.PropagationBinding, error)
List(ctx context.Context, opts v1.ListOptions) (*v1alpha1.PropagationBindingList, error)
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.PropagationBinding, err error)
PropagationBindingExpansion
}
// propagationBindings implements PropagationBindingInterface
type propagationBindings struct {
client rest.Interface
ns string
}
// newPropagationBindings returns a PropagationBindings
func newPropagationBindings(c *PropagationstrategyV1alpha1Client, namespace string) *propagationBindings {
return &propagationBindings{
client: c.RESTClient(),
ns: namespace,
}
}
// Get takes name of the propagationBinding, and returns the corresponding propagationBinding object, and an error if there is any.
func (c *propagationBindings) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha1.PropagationBinding, err error) {
result = &v1alpha1.PropagationBinding{}
err = c.client.Get().
Namespace(c.ns).
Resource("propagationbindings").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do(ctx).
Into(result)
return
}
// List takes label and field selectors, and returns the list of PropagationBindings that match those selectors.
func (c *propagationBindings) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha1.PropagationBindingList, err error) {
var timeout time.Duration
if opts.TimeoutSeconds != nil {
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
}
result = &v1alpha1.PropagationBindingList{}
err = c.client.Get().
Namespace(c.ns).
Resource("propagationbindings").
VersionedParams(&opts, scheme.ParameterCodec).
Timeout(timeout).
Do(ctx).
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested propagationBindings.
func (c *propagationBindings) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
var timeout time.Duration
if opts.TimeoutSeconds != nil {
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
}
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("propagationbindings").
VersionedParams(&opts, scheme.ParameterCodec).
Timeout(timeout).
Watch(ctx)
}
// Create takes the representation of a propagationBinding and creates it. Returns the server's representation of the propagationBinding, and an error, if there is any.
func (c *propagationBindings) Create(ctx context.Context, propagationBinding *v1alpha1.PropagationBinding, opts v1.CreateOptions) (result *v1alpha1.PropagationBinding, err error) {
result = &v1alpha1.PropagationBinding{}
err = c.client.Post().
Namespace(c.ns).
Resource("propagationbindings").
VersionedParams(&opts, scheme.ParameterCodec).
Body(propagationBinding).
Do(ctx).
Into(result)
return
}
// Update takes the representation of a propagationBinding and updates it. Returns the server's representation of the propagationBinding, and an error, if there is any.
func (c *propagationBindings) Update(ctx context.Context, propagationBinding *v1alpha1.PropagationBinding, opts v1.UpdateOptions) (result *v1alpha1.PropagationBinding, err error) {
result = &v1alpha1.PropagationBinding{}
err = c.client.Put().
Namespace(c.ns).
Resource("propagationbindings").
Name(propagationBinding.Name).
VersionedParams(&opts, scheme.ParameterCodec).
Body(propagationBinding).
Do(ctx).
Into(result)
return
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *propagationBindings) UpdateStatus(ctx context.Context, propagationBinding *v1alpha1.PropagationBinding, opts v1.UpdateOptions) (result *v1alpha1.PropagationBinding, err error) {
result = &v1alpha1.PropagationBinding{}
err = c.client.Put().
Namespace(c.ns).
Resource("propagationbindings").
Name(propagationBinding.Name).
SubResource("status").
VersionedParams(&opts, scheme.ParameterCodec).
Body(propagationBinding).
Do(ctx).
Into(result)
return
}
// Delete takes name of the propagationBinding and deletes it. Returns an error if one occurs.
func (c *propagationBindings) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
return c.client.Delete().
Namespace(c.ns).
Resource("propagationbindings").
Name(name).
Body(&opts).
Do(ctx).
Error()
}
// DeleteCollection deletes a collection of objects.
func (c *propagationBindings) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
var timeout time.Duration
if listOpts.TimeoutSeconds != nil {
timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second
}
return c.client.Delete().
Namespace(c.ns).
Resource("propagationbindings").
VersionedParams(&listOpts, scheme.ParameterCodec).
Timeout(timeout).
Body(&opts).
Do(ctx).
Error()
}
// Patch applies the patch and returns the patched propagationBinding.
func (c *propagationBindings) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.PropagationBinding, err error) {
result = &v1alpha1.PropagationBinding{}
err = c.client.Patch(pt).
Namespace(c.ns).
Resource("propagationbindings").
Name(name).
SubResource(subresources...).
VersionedParams(&opts, scheme.ParameterCodec).
Body(data).
Do(ctx).
Into(result)
return
}

View File

@ -1,162 +0,0 @@
// Code generated by client-gen. DO NOT EDIT.
package v1alpha1
import (
"context"
"time"
v1alpha1 "github.com/karmada-io/karmada/pkg/apis/propagationstrategy/v1alpha1"
scheme "github.com/karmada-io/karmada/pkg/generated/clientset/versioned/scheme"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
types "k8s.io/apimachinery/pkg/types"
watch "k8s.io/apimachinery/pkg/watch"
rest "k8s.io/client-go/rest"
)
// PropagationPoliciesGetter has a method to return a PropagationPolicyInterface.
// A group's client should implement this interface.
type PropagationPoliciesGetter interface {
PropagationPolicies(namespace string) PropagationPolicyInterface
}
// PropagationPolicyInterface has methods to work with PropagationPolicy resources.
type PropagationPolicyInterface interface {
Create(ctx context.Context, propagationPolicy *v1alpha1.PropagationPolicy, opts v1.CreateOptions) (*v1alpha1.PropagationPolicy, error)
Update(ctx context.Context, propagationPolicy *v1alpha1.PropagationPolicy, opts v1.UpdateOptions) (*v1alpha1.PropagationPolicy, error)
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha1.PropagationPolicy, error)
List(ctx context.Context, opts v1.ListOptions) (*v1alpha1.PropagationPolicyList, error)
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.PropagationPolicy, err error)
PropagationPolicyExpansion
}
// propagationPolicies implements PropagationPolicyInterface
type propagationPolicies struct {
client rest.Interface
ns string
}
// newPropagationPolicies returns a PropagationPolicies
func newPropagationPolicies(c *PropagationstrategyV1alpha1Client, namespace string) *propagationPolicies {
return &propagationPolicies{
client: c.RESTClient(),
ns: namespace,
}
}
// Get takes name of the propagationPolicy, and returns the corresponding propagationPolicy object, and an error if there is any.
func (c *propagationPolicies) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha1.PropagationPolicy, err error) {
result = &v1alpha1.PropagationPolicy{}
err = c.client.Get().
Namespace(c.ns).
Resource("propagationpolicies").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do(ctx).
Into(result)
return
}
// List takes label and field selectors, and returns the list of PropagationPolicies that match those selectors.
func (c *propagationPolicies) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha1.PropagationPolicyList, err error) {
var timeout time.Duration
if opts.TimeoutSeconds != nil {
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
}
result = &v1alpha1.PropagationPolicyList{}
err = c.client.Get().
Namespace(c.ns).
Resource("propagationpolicies").
VersionedParams(&opts, scheme.ParameterCodec).
Timeout(timeout).
Do(ctx).
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested propagationPolicies.
func (c *propagationPolicies) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
var timeout time.Duration
if opts.TimeoutSeconds != nil {
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
}
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("propagationpolicies").
VersionedParams(&opts, scheme.ParameterCodec).
Timeout(timeout).
Watch(ctx)
}
// Create takes the representation of a propagationPolicy and creates it. Returns the server's representation of the propagationPolicy, and an error, if there is any.
func (c *propagationPolicies) Create(ctx context.Context, propagationPolicy *v1alpha1.PropagationPolicy, opts v1.CreateOptions) (result *v1alpha1.PropagationPolicy, err error) {
result = &v1alpha1.PropagationPolicy{}
err = c.client.Post().
Namespace(c.ns).
Resource("propagationpolicies").
VersionedParams(&opts, scheme.ParameterCodec).
Body(propagationPolicy).
Do(ctx).
Into(result)
return
}
// Update takes the representation of a propagationPolicy and updates it. Returns the server's representation of the propagationPolicy, and an error, if there is any.
func (c *propagationPolicies) Update(ctx context.Context, propagationPolicy *v1alpha1.PropagationPolicy, opts v1.UpdateOptions) (result *v1alpha1.PropagationPolicy, err error) {
result = &v1alpha1.PropagationPolicy{}
err = c.client.Put().
Namespace(c.ns).
Resource("propagationpolicies").
Name(propagationPolicy.Name).
VersionedParams(&opts, scheme.ParameterCodec).
Body(propagationPolicy).
Do(ctx).
Into(result)
return
}
// Delete takes name of the propagationPolicy and deletes it. Returns an error if one occurs.
func (c *propagationPolicies) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
return c.client.Delete().
Namespace(c.ns).
Resource("propagationpolicies").
Name(name).
Body(&opts).
Do(ctx).
Error()
}
// DeleteCollection deletes a collection of objects.
func (c *propagationPolicies) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
var timeout time.Duration
if listOpts.TimeoutSeconds != nil {
timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second
}
return c.client.Delete().
Namespace(c.ns).
Resource("propagationpolicies").
VersionedParams(&listOpts, scheme.ParameterCodec).
Timeout(timeout).
Body(&opts).
Do(ctx).
Error()
}
// Patch applies the patch and returns the patched propagationPolicy.
func (c *propagationPolicies) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.PropagationPolicy, err error) {
result = &v1alpha1.PropagationPolicy{}
err = c.client.Patch(pt).
Namespace(c.ns).
Resource("propagationpolicies").
Name(name).
SubResource(subresources...).
VersionedParams(&opts, scheme.ParameterCodec).
Body(data).
Do(ctx).
Into(result)
return
}

View File

@ -1,88 +0,0 @@
// Code generated by client-gen. DO NOT EDIT.
package v1alpha1
import (
v1alpha1 "github.com/karmada-io/karmada/pkg/apis/propagationstrategy/v1alpha1"
"github.com/karmada-io/karmada/pkg/generated/clientset/versioned/scheme"
rest "k8s.io/client-go/rest"
)
type PropagationstrategyV1alpha1Interface interface {
RESTClient() rest.Interface
OverridePoliciesGetter
PropagationBindingsGetter
PropagationPoliciesGetter
PropagationWorksGetter
}
// PropagationstrategyV1alpha1Client is used to interact with features provided by the propagationstrategy.karmada.io group.
type PropagationstrategyV1alpha1Client struct {
restClient rest.Interface
}
func (c *PropagationstrategyV1alpha1Client) OverridePolicies(namespace string) OverridePolicyInterface {
return newOverridePolicies(c, namespace)
}
func (c *PropagationstrategyV1alpha1Client) PropagationBindings(namespace string) PropagationBindingInterface {
return newPropagationBindings(c, namespace)
}
func (c *PropagationstrategyV1alpha1Client) PropagationPolicies(namespace string) PropagationPolicyInterface {
return newPropagationPolicies(c, namespace)
}
func (c *PropagationstrategyV1alpha1Client) PropagationWorks(namespace string) PropagationWorkInterface {
return newPropagationWorks(c, namespace)
}
// NewForConfig creates a new PropagationstrategyV1alpha1Client for the given config.
func NewForConfig(c *rest.Config) (*PropagationstrategyV1alpha1Client, error) {
config := *c
if err := setConfigDefaults(&config); err != nil {
return nil, err
}
client, err := rest.RESTClientFor(&config)
if err != nil {
return nil, err
}
return &PropagationstrategyV1alpha1Client{client}, nil
}
// NewForConfigOrDie creates a new PropagationstrategyV1alpha1Client for the given config and
// panics if there is an error in the config.
func NewForConfigOrDie(c *rest.Config) *PropagationstrategyV1alpha1Client {
client, err := NewForConfig(c)
if err != nil {
panic(err)
}
return client
}
// New creates a new PropagationstrategyV1alpha1Client for the given RESTClient.
func New(c rest.Interface) *PropagationstrategyV1alpha1Client {
return &PropagationstrategyV1alpha1Client{c}
}
func setConfigDefaults(config *rest.Config) error {
gv := v1alpha1.SchemeGroupVersion
config.GroupVersion = &gv
config.APIPath = "/apis"
config.NegotiatedSerializer = scheme.Codecs.WithoutConversion()
if config.UserAgent == "" {
config.UserAgent = rest.DefaultKubernetesUserAgent()
}
return nil
}
// RESTClient returns a RESTClient that is used to communicate
// with API server by this client implementation.
func (c *PropagationstrategyV1alpha1Client) RESTClient() rest.Interface {
if c == nil {
return nil
}
return c.restClient
}

View File

@ -1,179 +0,0 @@
// Code generated by client-gen. DO NOT EDIT.
package v1alpha1
import (
"context"
"time"
v1alpha1 "github.com/karmada-io/karmada/pkg/apis/propagationstrategy/v1alpha1"
scheme "github.com/karmada-io/karmada/pkg/generated/clientset/versioned/scheme"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
types "k8s.io/apimachinery/pkg/types"
watch "k8s.io/apimachinery/pkg/watch"
rest "k8s.io/client-go/rest"
)
// PropagationWorksGetter has a method to return a PropagationWorkInterface.
// A group's client should implement this interface.
type PropagationWorksGetter interface {
PropagationWorks(namespace string) PropagationWorkInterface
}
// PropagationWorkInterface has methods to work with PropagationWork resources.
type PropagationWorkInterface interface {
Create(ctx context.Context, propagationWork *v1alpha1.PropagationWork, opts v1.CreateOptions) (*v1alpha1.PropagationWork, error)
Update(ctx context.Context, propagationWork *v1alpha1.PropagationWork, opts v1.UpdateOptions) (*v1alpha1.PropagationWork, error)
UpdateStatus(ctx context.Context, propagationWork *v1alpha1.PropagationWork, opts v1.UpdateOptions) (*v1alpha1.PropagationWork, error)
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha1.PropagationWork, error)
List(ctx context.Context, opts v1.ListOptions) (*v1alpha1.PropagationWorkList, error)
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.PropagationWork, err error)
PropagationWorkExpansion
}
// propagationWorks implements PropagationWorkInterface
type propagationWorks struct {
client rest.Interface
ns string
}
// newPropagationWorks returns a PropagationWorks
func newPropagationWorks(c *PropagationstrategyV1alpha1Client, namespace string) *propagationWorks {
return &propagationWorks{
client: c.RESTClient(),
ns: namespace,
}
}
// Get takes name of the propagationWork, and returns the corresponding propagationWork object, and an error if there is any.
func (c *propagationWorks) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha1.PropagationWork, err error) {
result = &v1alpha1.PropagationWork{}
err = c.client.Get().
Namespace(c.ns).
Resource("propagationworks").
Name(name).
VersionedParams(&options, scheme.ParameterCodec).
Do(ctx).
Into(result)
return
}
// List takes label and field selectors, and returns the list of PropagationWorks that match those selectors.
func (c *propagationWorks) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha1.PropagationWorkList, err error) {
var timeout time.Duration
if opts.TimeoutSeconds != nil {
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
}
result = &v1alpha1.PropagationWorkList{}
err = c.client.Get().
Namespace(c.ns).
Resource("propagationworks").
VersionedParams(&opts, scheme.ParameterCodec).
Timeout(timeout).
Do(ctx).
Into(result)
return
}
// Watch returns a watch.Interface that watches the requested propagationWorks.
func (c *propagationWorks) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
var timeout time.Duration
if opts.TimeoutSeconds != nil {
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
}
opts.Watch = true
return c.client.Get().
Namespace(c.ns).
Resource("propagationworks").
VersionedParams(&opts, scheme.ParameterCodec).
Timeout(timeout).
Watch(ctx)
}
// Create takes the representation of a propagationWork and creates it. Returns the server's representation of the propagationWork, and an error, if there is any.
func (c *propagationWorks) Create(ctx context.Context, propagationWork *v1alpha1.PropagationWork, opts v1.CreateOptions) (result *v1alpha1.PropagationWork, err error) {
result = &v1alpha1.PropagationWork{}
err = c.client.Post().
Namespace(c.ns).
Resource("propagationworks").
VersionedParams(&opts, scheme.ParameterCodec).
Body(propagationWork).
Do(ctx).
Into(result)
return
}
// Update takes the representation of a propagationWork and updates it. Returns the server's representation of the propagationWork, and an error, if there is any.
func (c *propagationWorks) Update(ctx context.Context, propagationWork *v1alpha1.PropagationWork, opts v1.UpdateOptions) (result *v1alpha1.PropagationWork, err error) {
result = &v1alpha1.PropagationWork{}
err = c.client.Put().
Namespace(c.ns).
Resource("propagationworks").
Name(propagationWork.Name).
VersionedParams(&opts, scheme.ParameterCodec).
Body(propagationWork).
Do(ctx).
Into(result)
return
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *propagationWorks) UpdateStatus(ctx context.Context, propagationWork *v1alpha1.PropagationWork, opts v1.UpdateOptions) (result *v1alpha1.PropagationWork, err error) {
result = &v1alpha1.PropagationWork{}
err = c.client.Put().
Namespace(c.ns).
Resource("propagationworks").
Name(propagationWork.Name).
SubResource("status").
VersionedParams(&opts, scheme.ParameterCodec).
Body(propagationWork).
Do(ctx).
Into(result)
return
}
// Delete takes name of the propagationWork and deletes it. Returns an error if one occurs.
func (c *propagationWorks) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
return c.client.Delete().
Namespace(c.ns).
Resource("propagationworks").
Name(name).
Body(&opts).
Do(ctx).
Error()
}
// DeleteCollection deletes a collection of objects.
func (c *propagationWorks) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
var timeout time.Duration
if listOpts.TimeoutSeconds != nil {
timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second
}
return c.client.Delete().
Namespace(c.ns).
Resource("propagationworks").
VersionedParams(&listOpts, scheme.ParameterCodec).
Timeout(timeout).
Body(&opts).
Do(ctx).
Error()
}
// Patch applies the patch and returns the patched propagationWork.
func (c *propagationWorks) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.PropagationWork, err error) {
result = &v1alpha1.PropagationWork{}
err = c.client.Patch(pt).
Namespace(c.ns).
Resource("propagationworks").
Name(name).
SubResource(subresources...).
VersionedParams(&opts, scheme.ParameterCodec).
Body(data).
Do(ctx).
Into(result)
return
}

View File

@ -1,30 +0,0 @@
// Code generated by informer-gen. DO NOT EDIT.
package propagationstrategy
import (
internalinterfaces "github.com/karmada-io/karmada/pkg/generated/informers/externalversions/internalinterfaces"
v1alpha1 "github.com/karmada-io/karmada/pkg/generated/informers/externalversions/propagationstrategy/v1alpha1"
)
// Interface provides access to each of this group's versions.
type Interface interface {
// V1alpha1 provides access to shared informers for resources in V1alpha1.
V1alpha1() v1alpha1.Interface
}
type group struct {
factory internalinterfaces.SharedInformerFactory
namespace string
tweakListOptions internalinterfaces.TweakListOptionsFunc
}
// New returns a new Interface.
func New(f internalinterfaces.SharedInformerFactory, namespace string, tweakListOptions internalinterfaces.TweakListOptionsFunc) Interface {
return &group{factory: f, namespace: namespace, tweakListOptions: tweakListOptions}
}
// V1alpha1 returns a new v1alpha1.Interface.
func (g *group) V1alpha1() v1alpha1.Interface {
return v1alpha1.New(g.factory, g.namespace, g.tweakListOptions)
}

View File

@ -1,50 +0,0 @@
// Code generated by informer-gen. DO NOT EDIT.
package v1alpha1
import (
internalinterfaces "github.com/karmada-io/karmada/pkg/generated/informers/externalversions/internalinterfaces"
)
// Interface provides access to all the informers in this group version.
type Interface interface {
// OverridePolicies returns a OverridePolicyInformer.
OverridePolicies() OverridePolicyInformer
// PropagationBindings returns a PropagationBindingInformer.
PropagationBindings() PropagationBindingInformer
// PropagationPolicies returns a PropagationPolicyInformer.
PropagationPolicies() PropagationPolicyInformer
// PropagationWorks returns a PropagationWorkInformer.
PropagationWorks() PropagationWorkInformer
}
type version struct {
factory internalinterfaces.SharedInformerFactory
namespace string
tweakListOptions internalinterfaces.TweakListOptionsFunc
}
// New returns a new Interface.
func New(f internalinterfaces.SharedInformerFactory, namespace string, tweakListOptions internalinterfaces.TweakListOptionsFunc) Interface {
return &version{factory: f, namespace: namespace, tweakListOptions: tweakListOptions}
}
// OverridePolicies returns a OverridePolicyInformer.
func (v *version) OverridePolicies() OverridePolicyInformer {
return &overridePolicyInformer{factory: v.factory, namespace: v.namespace, tweakListOptions: v.tweakListOptions}
}
// PropagationBindings returns a PropagationBindingInformer.
func (v *version) PropagationBindings() PropagationBindingInformer {
return &propagationBindingInformer{factory: v.factory, namespace: v.namespace, tweakListOptions: v.tweakListOptions}
}
// PropagationPolicies returns a PropagationPolicyInformer.
func (v *version) PropagationPolicies() PropagationPolicyInformer {
return &propagationPolicyInformer{factory: v.factory, namespace: v.namespace, tweakListOptions: v.tweakListOptions}
}
// PropagationWorks returns a PropagationWorkInformer.
func (v *version) PropagationWorks() PropagationWorkInformer {
return &propagationWorkInformer{factory: v.factory, namespace: v.namespace, tweakListOptions: v.tweakListOptions}
}

View File

@ -1,74 +0,0 @@
// Code generated by informer-gen. DO NOT EDIT.
package v1alpha1
import (
"context"
time "time"
propagationstrategyv1alpha1 "github.com/karmada-io/karmada/pkg/apis/propagationstrategy/v1alpha1"
versioned "github.com/karmada-io/karmada/pkg/generated/clientset/versioned"
internalinterfaces "github.com/karmada-io/karmada/pkg/generated/informers/externalversions/internalinterfaces"
v1alpha1 "github.com/karmada-io/karmada/pkg/generated/listers/propagationstrategy/v1alpha1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
// OverridePolicyInformer provides access to a shared informer and lister for
// OverridePolicies.
type OverridePolicyInformer interface {
Informer() cache.SharedIndexInformer
Lister() v1alpha1.OverridePolicyLister
}
type overridePolicyInformer struct {
factory internalinterfaces.SharedInformerFactory
tweakListOptions internalinterfaces.TweakListOptionsFunc
namespace string
}
// NewOverridePolicyInformer constructs a new informer for OverridePolicy type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewOverridePolicyInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
return NewFilteredOverridePolicyInformer(client, namespace, resyncPeriod, indexers, nil)
}
// NewFilteredOverridePolicyInformer constructs a new informer for OverridePolicy type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredOverridePolicyInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
return cache.NewSharedIndexInformer(
&cache.ListWatch{
ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
tweakListOptions(&options)
}
return client.PropagationstrategyV1alpha1().OverridePolicies(namespace).List(context.TODO(), options)
},
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
tweakListOptions(&options)
}
return client.PropagationstrategyV1alpha1().OverridePolicies(namespace).Watch(context.TODO(), options)
},
},
&propagationstrategyv1alpha1.OverridePolicy{},
resyncPeriod,
indexers,
)
}
func (f *overridePolicyInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
return NewFilteredOverridePolicyInformer(client, f.namespace, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
}
func (f *overridePolicyInformer) Informer() cache.SharedIndexInformer {
return f.factory.InformerFor(&propagationstrategyv1alpha1.OverridePolicy{}, f.defaultInformer)
}
func (f *overridePolicyInformer) Lister() v1alpha1.OverridePolicyLister {
return v1alpha1.NewOverridePolicyLister(f.Informer().GetIndexer())
}

View File

@ -1,74 +0,0 @@
// Code generated by informer-gen. DO NOT EDIT.
package v1alpha1
import (
"context"
time "time"
propagationstrategyv1alpha1 "github.com/karmada-io/karmada/pkg/apis/propagationstrategy/v1alpha1"
versioned "github.com/karmada-io/karmada/pkg/generated/clientset/versioned"
internalinterfaces "github.com/karmada-io/karmada/pkg/generated/informers/externalversions/internalinterfaces"
v1alpha1 "github.com/karmada-io/karmada/pkg/generated/listers/propagationstrategy/v1alpha1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
// PropagationBindingInformer provides access to a shared informer and lister for
// PropagationBindings.
type PropagationBindingInformer interface {
Informer() cache.SharedIndexInformer
Lister() v1alpha1.PropagationBindingLister
}
type propagationBindingInformer struct {
factory internalinterfaces.SharedInformerFactory
tweakListOptions internalinterfaces.TweakListOptionsFunc
namespace string
}
// NewPropagationBindingInformer constructs a new informer for PropagationBinding type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewPropagationBindingInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
return NewFilteredPropagationBindingInformer(client, namespace, resyncPeriod, indexers, nil)
}
// NewFilteredPropagationBindingInformer constructs a new informer for PropagationBinding type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredPropagationBindingInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
return cache.NewSharedIndexInformer(
&cache.ListWatch{
ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
tweakListOptions(&options)
}
return client.PropagationstrategyV1alpha1().PropagationBindings(namespace).List(context.TODO(), options)
},
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
tweakListOptions(&options)
}
return client.PropagationstrategyV1alpha1().PropagationBindings(namespace).Watch(context.TODO(), options)
},
},
&propagationstrategyv1alpha1.PropagationBinding{},
resyncPeriod,
indexers,
)
}
func (f *propagationBindingInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
return NewFilteredPropagationBindingInformer(client, f.namespace, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
}
func (f *propagationBindingInformer) Informer() cache.SharedIndexInformer {
return f.factory.InformerFor(&propagationstrategyv1alpha1.PropagationBinding{}, f.defaultInformer)
}
func (f *propagationBindingInformer) Lister() v1alpha1.PropagationBindingLister {
return v1alpha1.NewPropagationBindingLister(f.Informer().GetIndexer())
}

View File

@ -1,74 +0,0 @@
// Code generated by informer-gen. DO NOT EDIT.
package v1alpha1
import (
"context"
time "time"
propagationstrategyv1alpha1 "github.com/karmada-io/karmada/pkg/apis/propagationstrategy/v1alpha1"
versioned "github.com/karmada-io/karmada/pkg/generated/clientset/versioned"
internalinterfaces "github.com/karmada-io/karmada/pkg/generated/informers/externalversions/internalinterfaces"
v1alpha1 "github.com/karmada-io/karmada/pkg/generated/listers/propagationstrategy/v1alpha1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
// PropagationPolicyInformer provides access to a shared informer and lister for
// PropagationPolicies.
type PropagationPolicyInformer interface {
Informer() cache.SharedIndexInformer
Lister() v1alpha1.PropagationPolicyLister
}
type propagationPolicyInformer struct {
factory internalinterfaces.SharedInformerFactory
tweakListOptions internalinterfaces.TweakListOptionsFunc
namespace string
}
// NewPropagationPolicyInformer constructs a new informer for PropagationPolicy type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewPropagationPolicyInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
return NewFilteredPropagationPolicyInformer(client, namespace, resyncPeriod, indexers, nil)
}
// NewFilteredPropagationPolicyInformer constructs a new informer for PropagationPolicy type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredPropagationPolicyInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
return cache.NewSharedIndexInformer(
&cache.ListWatch{
ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
tweakListOptions(&options)
}
return client.PropagationstrategyV1alpha1().PropagationPolicies(namespace).List(context.TODO(), options)
},
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
tweakListOptions(&options)
}
return client.PropagationstrategyV1alpha1().PropagationPolicies(namespace).Watch(context.TODO(), options)
},
},
&propagationstrategyv1alpha1.PropagationPolicy{},
resyncPeriod,
indexers,
)
}
func (f *propagationPolicyInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
return NewFilteredPropagationPolicyInformer(client, f.namespace, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
}
func (f *propagationPolicyInformer) Informer() cache.SharedIndexInformer {
return f.factory.InformerFor(&propagationstrategyv1alpha1.PropagationPolicy{}, f.defaultInformer)
}
func (f *propagationPolicyInformer) Lister() v1alpha1.PropagationPolicyLister {
return v1alpha1.NewPropagationPolicyLister(f.Informer().GetIndexer())
}

View File

@ -1,74 +0,0 @@
// Code generated by informer-gen. DO NOT EDIT.
package v1alpha1
import (
"context"
time "time"
propagationstrategyv1alpha1 "github.com/karmada-io/karmada/pkg/apis/propagationstrategy/v1alpha1"
versioned "github.com/karmada-io/karmada/pkg/generated/clientset/versioned"
internalinterfaces "github.com/karmada-io/karmada/pkg/generated/informers/externalversions/internalinterfaces"
v1alpha1 "github.com/karmada-io/karmada/pkg/generated/listers/propagationstrategy/v1alpha1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
watch "k8s.io/apimachinery/pkg/watch"
cache "k8s.io/client-go/tools/cache"
)
// PropagationWorkInformer provides access to a shared informer and lister for
// PropagationWorks.
type PropagationWorkInformer interface {
Informer() cache.SharedIndexInformer
Lister() v1alpha1.PropagationWorkLister
}
type propagationWorkInformer struct {
factory internalinterfaces.SharedInformerFactory
tweakListOptions internalinterfaces.TweakListOptionsFunc
namespace string
}
// NewPropagationWorkInformer constructs a new informer for PropagationWork type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewPropagationWorkInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
return NewFilteredPropagationWorkInformer(client, namespace, resyncPeriod, indexers, nil)
}
// NewFilteredPropagationWorkInformer constructs a new informer for PropagationWork type.
// Always prefer using an informer factory to get a shared informer instead of getting an independent
// one. This reduces memory footprint and number of connections to the server.
func NewFilteredPropagationWorkInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
return cache.NewSharedIndexInformer(
&cache.ListWatch{
ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
if tweakListOptions != nil {
tweakListOptions(&options)
}
return client.PropagationstrategyV1alpha1().PropagationWorks(namespace).List(context.TODO(), options)
},
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
if tweakListOptions != nil {
tweakListOptions(&options)
}
return client.PropagationstrategyV1alpha1().PropagationWorks(namespace).Watch(context.TODO(), options)
},
},
&propagationstrategyv1alpha1.PropagationWork{},
resyncPeriod,
indexers,
)
}
func (f *propagationWorkInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
return NewFilteredPropagationWorkInformer(client, f.namespace, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
}
func (f *propagationWorkInformer) Informer() cache.SharedIndexInformer {
return f.factory.InformerFor(&propagationstrategyv1alpha1.PropagationWork{}, f.defaultInformer)
}
func (f *propagationWorkInformer) Lister() v1alpha1.PropagationWorkLister {
return v1alpha1.NewPropagationWorkLister(f.Informer().GetIndexer())
}

View File

@ -1,35 +0,0 @@
// Code generated by lister-gen. DO NOT EDIT.
package v1alpha1
// OverridePolicyListerExpansion allows custom methods to be added to
// OverridePolicyLister.
type OverridePolicyListerExpansion interface{}
// OverridePolicyNamespaceListerExpansion allows custom methods to be added to
// OverridePolicyNamespaceLister.
type OverridePolicyNamespaceListerExpansion interface{}
// PropagationBindingListerExpansion allows custom methods to be added to
// PropagationBindingLister.
type PropagationBindingListerExpansion interface{}
// PropagationBindingNamespaceListerExpansion allows custom methods to be added to
// PropagationBindingNamespaceLister.
type PropagationBindingNamespaceListerExpansion interface{}
// PropagationPolicyListerExpansion allows custom methods to be added to
// PropagationPolicyLister.
type PropagationPolicyListerExpansion interface{}
// PropagationPolicyNamespaceListerExpansion allows custom methods to be added to
// PropagationPolicyNamespaceLister.
type PropagationPolicyNamespaceListerExpansion interface{}
// PropagationWorkListerExpansion allows custom methods to be added to
// PropagationWorkLister.
type PropagationWorkListerExpansion interface{}
// PropagationWorkNamespaceListerExpansion allows custom methods to be added to
// PropagationWorkNamespaceLister.
type PropagationWorkNamespaceListerExpansion interface{}

View File

@ -1,83 +0,0 @@
// Code generated by lister-gen. DO NOT EDIT.
package v1alpha1
import (
v1alpha1 "github.com/karmada-io/karmada/pkg/apis/propagationstrategy/v1alpha1"
"k8s.io/apimachinery/pkg/api/errors"
"k8s.io/apimachinery/pkg/labels"
"k8s.io/client-go/tools/cache"
)
// OverridePolicyLister helps list OverridePolicies.
// All objects returned here must be treated as read-only.
type OverridePolicyLister interface {
// List lists all OverridePolicies in the indexer.
// Objects returned here must be treated as read-only.
List(selector labels.Selector) (ret []*v1alpha1.OverridePolicy, err error)
// OverridePolicies returns an object that can list and get OverridePolicies.
OverridePolicies(namespace string) OverridePolicyNamespaceLister
OverridePolicyListerExpansion
}
// overridePolicyLister implements the OverridePolicyLister interface.
type overridePolicyLister struct {
indexer cache.Indexer
}
// NewOverridePolicyLister returns a new OverridePolicyLister.
func NewOverridePolicyLister(indexer cache.Indexer) OverridePolicyLister {
return &overridePolicyLister{indexer: indexer}
}
// List lists all OverridePolicies in the indexer.
func (s *overridePolicyLister) List(selector labels.Selector) (ret []*v1alpha1.OverridePolicy, err error) {
err = cache.ListAll(s.indexer, selector, func(m interface{}) {
ret = append(ret, m.(*v1alpha1.OverridePolicy))
})
return ret, err
}
// OverridePolicies returns an object that can list and get OverridePolicies.
func (s *overridePolicyLister) OverridePolicies(namespace string) OverridePolicyNamespaceLister {
return overridePolicyNamespaceLister{indexer: s.indexer, namespace: namespace}
}
// OverridePolicyNamespaceLister helps list and get OverridePolicies.
// All objects returned here must be treated as read-only.
type OverridePolicyNamespaceLister interface {
// List lists all OverridePolicies in the indexer for a given namespace.
// Objects returned here must be treated as read-only.
List(selector labels.Selector) (ret []*v1alpha1.OverridePolicy, err error)
// Get retrieves the OverridePolicy from the indexer for a given namespace and name.
// Objects returned here must be treated as read-only.
Get(name string) (*v1alpha1.OverridePolicy, error)
OverridePolicyNamespaceListerExpansion
}
// overridePolicyNamespaceLister implements the OverridePolicyNamespaceLister
// interface.
type overridePolicyNamespaceLister struct {
indexer cache.Indexer
namespace string
}
// List lists all OverridePolicies in the indexer for a given namespace.
func (s overridePolicyNamespaceLister) List(selector labels.Selector) (ret []*v1alpha1.OverridePolicy, err error) {
err = cache.ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) {
ret = append(ret, m.(*v1alpha1.OverridePolicy))
})
return ret, err
}
// Get retrieves the OverridePolicy from the indexer for a given namespace and name.
func (s overridePolicyNamespaceLister) Get(name string) (*v1alpha1.OverridePolicy, error) {
obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name)
if err != nil {
return nil, err
}
if !exists {
return nil, errors.NewNotFound(v1alpha1.Resource("overridepolicy"), name)
}
return obj.(*v1alpha1.OverridePolicy), nil
}

View File

@ -1,83 +0,0 @@
// Code generated by lister-gen. DO NOT EDIT.
package v1alpha1
import (
v1alpha1 "github.com/karmada-io/karmada/pkg/apis/propagationstrategy/v1alpha1"
"k8s.io/apimachinery/pkg/api/errors"
"k8s.io/apimachinery/pkg/labels"
"k8s.io/client-go/tools/cache"
)
// PropagationBindingLister helps list PropagationBindings.
// All objects returned here must be treated as read-only.
type PropagationBindingLister interface {
// List lists all PropagationBindings in the indexer.
// Objects returned here must be treated as read-only.
List(selector labels.Selector) (ret []*v1alpha1.PropagationBinding, err error)
// PropagationBindings returns an object that can list and get PropagationBindings.
PropagationBindings(namespace string) PropagationBindingNamespaceLister
PropagationBindingListerExpansion
}
// propagationBindingLister implements the PropagationBindingLister interface.
type propagationBindingLister struct {
indexer cache.Indexer
}
// NewPropagationBindingLister returns a new PropagationBindingLister.
func NewPropagationBindingLister(indexer cache.Indexer) PropagationBindingLister {
return &propagationBindingLister{indexer: indexer}
}
// List lists all PropagationBindings in the indexer.
func (s *propagationBindingLister) List(selector labels.Selector) (ret []*v1alpha1.PropagationBinding, err error) {
err = cache.ListAll(s.indexer, selector, func(m interface{}) {
ret = append(ret, m.(*v1alpha1.PropagationBinding))
})
return ret, err
}
// PropagationBindings returns an object that can list and get PropagationBindings.
func (s *propagationBindingLister) PropagationBindings(namespace string) PropagationBindingNamespaceLister {
return propagationBindingNamespaceLister{indexer: s.indexer, namespace: namespace}
}
// PropagationBindingNamespaceLister helps list and get PropagationBindings.
// All objects returned here must be treated as read-only.
type PropagationBindingNamespaceLister interface {
// List lists all PropagationBindings in the indexer for a given namespace.
// Objects returned here must be treated as read-only.
List(selector labels.Selector) (ret []*v1alpha1.PropagationBinding, err error)
// Get retrieves the PropagationBinding from the indexer for a given namespace and name.
// Objects returned here must be treated as read-only.
Get(name string) (*v1alpha1.PropagationBinding, error)
PropagationBindingNamespaceListerExpansion
}
// propagationBindingNamespaceLister implements the PropagationBindingNamespaceLister
// interface.
type propagationBindingNamespaceLister struct {
indexer cache.Indexer
namespace string
}
// List lists all PropagationBindings in the indexer for a given namespace.
func (s propagationBindingNamespaceLister) List(selector labels.Selector) (ret []*v1alpha1.PropagationBinding, err error) {
err = cache.ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) {
ret = append(ret, m.(*v1alpha1.PropagationBinding))
})
return ret, err
}
// Get retrieves the PropagationBinding from the indexer for a given namespace and name.
func (s propagationBindingNamespaceLister) Get(name string) (*v1alpha1.PropagationBinding, error) {
obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name)
if err != nil {
return nil, err
}
if !exists {
return nil, errors.NewNotFound(v1alpha1.Resource("propagationbinding"), name)
}
return obj.(*v1alpha1.PropagationBinding), nil
}

View File

@ -1,83 +0,0 @@
// Code generated by lister-gen. DO NOT EDIT.
package v1alpha1
import (
v1alpha1 "github.com/karmada-io/karmada/pkg/apis/propagationstrategy/v1alpha1"
"k8s.io/apimachinery/pkg/api/errors"
"k8s.io/apimachinery/pkg/labels"
"k8s.io/client-go/tools/cache"
)
// PropagationPolicyLister helps list PropagationPolicies.
// All objects returned here must be treated as read-only.
type PropagationPolicyLister interface {
// List lists all PropagationPolicies in the indexer.
// Objects returned here must be treated as read-only.
List(selector labels.Selector) (ret []*v1alpha1.PropagationPolicy, err error)
// PropagationPolicies returns an object that can list and get PropagationPolicies.
PropagationPolicies(namespace string) PropagationPolicyNamespaceLister
PropagationPolicyListerExpansion
}
// propagationPolicyLister implements the PropagationPolicyLister interface.
type propagationPolicyLister struct {
indexer cache.Indexer
}
// NewPropagationPolicyLister returns a new PropagationPolicyLister.
func NewPropagationPolicyLister(indexer cache.Indexer) PropagationPolicyLister {
return &propagationPolicyLister{indexer: indexer}
}
// List lists all PropagationPolicies in the indexer.
func (s *propagationPolicyLister) List(selector labels.Selector) (ret []*v1alpha1.PropagationPolicy, err error) {
err = cache.ListAll(s.indexer, selector, func(m interface{}) {
ret = append(ret, m.(*v1alpha1.PropagationPolicy))
})
return ret, err
}
// PropagationPolicies returns an object that can list and get PropagationPolicies.
func (s *propagationPolicyLister) PropagationPolicies(namespace string) PropagationPolicyNamespaceLister {
return propagationPolicyNamespaceLister{indexer: s.indexer, namespace: namespace}
}
// PropagationPolicyNamespaceLister helps list and get PropagationPolicies.
// All objects returned here must be treated as read-only.
type PropagationPolicyNamespaceLister interface {
// List lists all PropagationPolicies in the indexer for a given namespace.
// Objects returned here must be treated as read-only.
List(selector labels.Selector) (ret []*v1alpha1.PropagationPolicy, err error)
// Get retrieves the PropagationPolicy from the indexer for a given namespace and name.
// Objects returned here must be treated as read-only.
Get(name string) (*v1alpha1.PropagationPolicy, error)
PropagationPolicyNamespaceListerExpansion
}
// propagationPolicyNamespaceLister implements the PropagationPolicyNamespaceLister
// interface.
type propagationPolicyNamespaceLister struct {
indexer cache.Indexer
namespace string
}
// List lists all PropagationPolicies in the indexer for a given namespace.
func (s propagationPolicyNamespaceLister) List(selector labels.Selector) (ret []*v1alpha1.PropagationPolicy, err error) {
err = cache.ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) {
ret = append(ret, m.(*v1alpha1.PropagationPolicy))
})
return ret, err
}
// Get retrieves the PropagationPolicy from the indexer for a given namespace and name.
func (s propagationPolicyNamespaceLister) Get(name string) (*v1alpha1.PropagationPolicy, error) {
obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name)
if err != nil {
return nil, err
}
if !exists {
return nil, errors.NewNotFound(v1alpha1.Resource("propagationpolicy"), name)
}
return obj.(*v1alpha1.PropagationPolicy), nil
}

View File

@ -1,83 +0,0 @@
// Code generated by lister-gen. DO NOT EDIT.
package v1alpha1
import (
v1alpha1 "github.com/karmada-io/karmada/pkg/apis/propagationstrategy/v1alpha1"
"k8s.io/apimachinery/pkg/api/errors"
"k8s.io/apimachinery/pkg/labels"
"k8s.io/client-go/tools/cache"
)
// PropagationWorkLister helps list PropagationWorks.
// All objects returned here must be treated as read-only.
type PropagationWorkLister interface {
// List lists all PropagationWorks in the indexer.
// Objects returned here must be treated as read-only.
List(selector labels.Selector) (ret []*v1alpha1.PropagationWork, err error)
// PropagationWorks returns an object that can list and get PropagationWorks.
PropagationWorks(namespace string) PropagationWorkNamespaceLister
PropagationWorkListerExpansion
}
// propagationWorkLister implements the PropagationWorkLister interface.
type propagationWorkLister struct {
indexer cache.Indexer
}
// NewPropagationWorkLister returns a new PropagationWorkLister.
func NewPropagationWorkLister(indexer cache.Indexer) PropagationWorkLister {
return &propagationWorkLister{indexer: indexer}
}
// List lists all PropagationWorks in the indexer.
func (s *propagationWorkLister) List(selector labels.Selector) (ret []*v1alpha1.PropagationWork, err error) {
err = cache.ListAll(s.indexer, selector, func(m interface{}) {
ret = append(ret, m.(*v1alpha1.PropagationWork))
})
return ret, err
}
// PropagationWorks returns an object that can list and get PropagationWorks.
func (s *propagationWorkLister) PropagationWorks(namespace string) PropagationWorkNamespaceLister {
return propagationWorkNamespaceLister{indexer: s.indexer, namespace: namespace}
}
// PropagationWorkNamespaceLister helps list and get PropagationWorks.
// All objects returned here must be treated as read-only.
type PropagationWorkNamespaceLister interface {
// List lists all PropagationWorks in the indexer for a given namespace.
// Objects returned here must be treated as read-only.
List(selector labels.Selector) (ret []*v1alpha1.PropagationWork, err error)
// Get retrieves the PropagationWork from the indexer for a given namespace and name.
// Objects returned here must be treated as read-only.
Get(name string) (*v1alpha1.PropagationWork, error)
PropagationWorkNamespaceListerExpansion
}
// propagationWorkNamespaceLister implements the PropagationWorkNamespaceLister
// interface.
type propagationWorkNamespaceLister struct {
indexer cache.Indexer
namespace string
}
// List lists all PropagationWorks in the indexer for a given namespace.
func (s propagationWorkNamespaceLister) List(selector labels.Selector) (ret []*v1alpha1.PropagationWork, err error) {
err = cache.ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) {
ret = append(ret, m.(*v1alpha1.PropagationWork))
})
return ret, err
}
// Get retrieves the PropagationWork from the indexer for a given namespace and name.
func (s propagationWorkNamespaceLister) Get(name string) (*v1alpha1.PropagationWork, error) {
obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name)
if err != nil {
return nil, err
}
if !exists {
return nil, errors.NewNotFound(v1alpha1.Resource("propagationwork"), name)
}
return obj.(*v1alpha1.PropagationWork), nil
}