Interface KubernetesSharedWatcher<T>
-
- All Superinterfaces:
AutoCloseable
- All Known Subinterfaces:
KubernetesConfigMapSharedWatcher
- All Known Implementing Classes:
KubernetesConfigMapSharedInformer,KubernetesSharedInformer
public interface KubernetesSharedWatcher<T> extends AutoCloseable
The interface for the Kubernetes shared watcher.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interfaceKubernetesSharedWatcher.WatchThe Watch returned after creating watching, which can be used to close the watching.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidclose()Close the shared watcher without Exception.KubernetesSharedWatcher.Watchwatch(String name, FlinkKubeClient.WatchCallbackHandler<T> callbackHandler, Executor executor)Watch the Kubernetes resource with specified name and do theFlinkKubeClient.WatchCallbackHandler.
-
-
-
Method Detail
-
close
void close()
Close the shared watcher without Exception.- Specified by:
closein interfaceAutoCloseable
-
watch
KubernetesSharedWatcher.Watch watch(String name, FlinkKubeClient.WatchCallbackHandler<T> callbackHandler, @Nullable Executor executor)
Watch the Kubernetes resource with specified name and do theFlinkKubeClient.WatchCallbackHandler.- Parameters:
name- name to filter the resource to watchcallbackHandler- callbackHandler which reacts to resource eventsexecutor- to run callback- Returns:
- Return a watch for the Kubernetes resource. It needs to be closed after use.
-
-