public class HasMetadataOperation<T extends io.fabric8.kubernetes.api.model.HasMetadata,L extends io.fabric8.kubernetes.api.model.KubernetesResourceList<T>,R extends Resource<T>> extends BaseOperation<T,L,R>
FieldValidateable.Validation
Modifier and Type | Field and Description |
---|---|
static long |
DEFAULT_GRACE_PERIOD_IN_SECONDS |
static io.fabric8.kubernetes.api.model.DeletionPropagation |
DEFAULT_PROPAGATION_POLICY |
apiVersion, listType
type
apiGroupName, apiGroupVersion, config, context, dryRun, httpClient, JSON, JSON_MAPPER, JSON_MERGE_PATCH, JSON_PATCH, name, namespace, resourceT, STRATEGIC_MERGE_JSON_PATCH, subresource
Constructor and Description |
---|
HasMetadataOperation(OperationContext ctx,
Class<T> type,
Class<L> listType) |
Modifier and Type | Method and Description |
---|---|
T |
accept(Consumer<T> consumer) |
T |
edit(UnaryOperator<T> function) |
T |
edit(io.fabric8.kubernetes.api.builder.Visitor... visitors) |
T |
editStatus(UnaryOperator<T> function) |
protected T |
modifyItemForReplaceOrPatch(Supplier<T> current,
T item)
Modify the item prior to a replace or a JSON patch diff
|
HasMetadataOperation<T,L,R> |
newInstance(OperationContext context) |
T |
patch() |
T |
patch(PatchContext patchContext) |
T |
patch(PatchContext patchContext,
String patch) |
T |
patch(PatchContext patchContext,
T item) |
protected T |
patch(PatchContext context,
T base,
T item,
boolean status)
Perform a patch.
|
T |
patchStatus() |
T |
patchStatus(T item) |
T |
replace() |
protected T |
replace(T item,
boolean status)
base replace operation, which is effectively a forced update with retries
|
T |
replaceStatus() |
T |
update() |
protected T |
update(T item,
boolean status) |
T |
updateStatus() |
appendListOptionParams, create, createOrReplace, createOrReplace, delete, delete, delete, deleteAll, dryRun, dryRun, edit, fetchListUrl, fieldManager, fieldValidation, forceConflicts, forOperationType, fromServer, get, getApiEndpointPath, getConfigType, getFieldQueryParam, getGracePeriodSeconds, getGroup, getItem, getItemOrRequireFromServer, getKind, getLimit, getListType, getNonNullItem, getOperationType, getPlural, getPropagationPolicy, getReadiness, getResourceVersion, getVersion, getWatchReconnectInterval, handleCreate, handleDeploymentRollback, handleGet, handlePatch, handleResponse, handleScale, handleUpdate, inAnyNamespace, inform, informOnCondition, inNamespace, inWriteContext, isReady, isResourceNamespaced, item, list, list, list, load, load, load, load, lockResourceVersion, lockResourceVersion, newResource, replace, replaceStatus, require, requireFromServer, resource, resources, runnableInformer, serverSideApply, setListType, setType, submitList, submitWatch, updateApiVersion, updateApiVersion, updateStatus, waitUntilCondition, waitUntilReady, watch, watch, watch, withField, withFields, withGracePeriod, withIndexers, withInvolvedObject, withLabel, withLabelIn, withLabelNotIn, withLabels, withLabelSelector, withLabelSelector, withLimit, withName, withNewFilter, withoutField, withoutFields, withoutLabel, withoutLabels, withPropagationPolicy, withResourceVersion, withTimeout
create, getType
addNamespacedUrlPathParts, assertResponseCode, checkName, checkNamespace, correctNamespace, createStatus, createStatus, getAPIGroupName, getAPIGroupVersion, getConfig, getName, getNamespace, getNamespacedUrl, getNamespacedUrl, getNamespacedUrl, getObjectValueAsMap, getOperationContext, getRequestConfig, getResourceT, getResourceUrl, getResourceUrl, getResourceUrl, getResourceURLForPatchOperation, getResourceURLForWriteOperation, getRootUrlParts, handleApproveOrDeny, handleCreate, handleDelete, handleDeploymentRollback, handleGet, handleMetric, handlePatch, handlePatch, handleRawGet, handleResponse, handleResponse, handleScale, handleUpdate, requestException, requestException, requestFailure, requestFailure, restCall, unmarshal, unmarshal, unmarshal, waitForResult
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getFullResourceName, getName, getNamespace
delete
withLabel, withoutLabel
inform, inform
withTimeoutInMillis
patch, patch
create
public static final io.fabric8.kubernetes.api.model.DeletionPropagation DEFAULT_PROPAGATION_POLICY
public static final long DEFAULT_GRACE_PERIOD_IN_SECONDS
public HasMetadataOperation(OperationContext ctx, Class<T> type, Class<L> listType)
public T edit(UnaryOperator<T> function)
public T editStatus(UnaryOperator<T> function)
editStatus
in interface EditReplacePatchable<T extends io.fabric8.kubernetes.api.model.HasMetadata>
editStatus
in class BaseOperation<T extends io.fabric8.kubernetes.api.model.HasMetadata,L extends io.fabric8.kubernetes.api.model.KubernetesResourceList<T>,R extends Resource<T>>
public T edit(io.fabric8.kubernetes.api.builder.Visitor... visitors)
public T replace()
public T replaceStatus()
replaceStatus
in interface Replaceable<T extends io.fabric8.kubernetes.api.model.HasMetadata>
replaceStatus
in class BaseOperation<T extends io.fabric8.kubernetes.api.model.HasMetadata,L extends io.fabric8.kubernetes.api.model.KubernetesResourceList<T>,R extends Resource<T>>
protected T modifyItemForReplaceOrPatch(Supplier<T> current, T item)
current
- item from the serveritem
- to be modifiedpublic T update()
public T updateStatus()
updateStatus
in interface Replaceable<T extends io.fabric8.kubernetes.api.model.HasMetadata>
updateStatus
in class BaseOperation<T extends io.fabric8.kubernetes.api.model.HasMetadata,L extends io.fabric8.kubernetes.api.model.KubernetesResourceList<T>,R extends Resource<T>>
protected T replace(T item, boolean status)
protected T patch(PatchContext context, T base, T item, boolean status)
public T patchStatus()
patchStatus
in interface EditReplacePatchable<T extends io.fabric8.kubernetes.api.model.HasMetadata>
patchStatus
in class BaseOperation<T extends io.fabric8.kubernetes.api.model.HasMetadata,L extends io.fabric8.kubernetes.api.model.KubernetesResourceList<T>,R extends Resource<T>>
public T patch()
public T patch(PatchContext patchContext)
public T patchStatus(T item)
patchStatus
in interface ItemWritableOperation<T extends io.fabric8.kubernetes.api.model.HasMetadata>
patchStatus
in class BaseOperation<T extends io.fabric8.kubernetes.api.model.HasMetadata,L extends io.fabric8.kubernetes.api.model.KubernetesResourceList<T>,R extends Resource<T>>
public T patch(PatchContext patchContext, T item)
public T patch(PatchContext patchContext, String patch)
public HasMetadataOperation<T,L,R> newInstance(OperationContext context)
newInstance
in class BaseOperation<T extends io.fabric8.kubernetes.api.model.HasMetadata,L extends io.fabric8.kubernetes.api.model.KubernetesResourceList<T>,R extends Resource<T>>
Copyright © 2015–2023 Red Hat. All rights reserved.