Class ControllerWatchBuilder<ApiType extends io.kubernetes.client.common.KubernetesObject>
java.lang.Object
io.kubernetes.client.extended.controller.builder.ControllerWatchBuilder<ApiType>
public class ControllerWatchBuilder<ApiType extends io.kubernetes.client.common.KubernetesObject>
extends Object
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
End building controller-watch.withOnAddFilter
(Predicate<ApiType> filter) Sets a filter for add notification.withOnDeleteFilter
(BiPredicate<ApiType, Boolean> filter) Sets a filter for delete notification.withOnUpdateFilter
(BiPredicate<ApiType, ApiType> filter) Sets a filter for update notification.withResyncPeriod
(Duration resyncPeriod) withWorkQueueKeyFunc
(Function<ApiType, Request> workKeyGenerator) Overrides work-queue key-func for the watch.
-
Method Details
-
withOnAddFilter
Sets a filter for add notification.- Parameters:
filter
- the filter- Returns:
- the controller builder . controller watch builder
-
withOnUpdateFilter
Sets a filter for update notification.- Parameters:
filter
- the filter- Returns:
- the controller builder . controller watch builder
-
withOnDeleteFilter
Sets a filter for delete notification.- Parameters:
filter
- the filter- Returns:
- the controller builder . controller watch builder
-
withWorkQueueKeyFunc
public ControllerWatchBuilder<ApiType> withWorkQueueKeyFunc(Function<ApiType, Request> workKeyGenerator) Overrides work-queue key-func for the watch.- Parameters:
workKeyGenerator
- the work key generator- Returns:
- the controller builder . controller watch builder
-
withResyncPeriod
-
build
End building controller-watch.- Returns:
- the controller builder
- Throws:
IllegalStateException
- the illegal state exception
-