Interface SharedIndexInformerFactory


public interface SharedIndexInformerFactory
Informer factory interface.
  • Method Details

    • sharedIndexInformerFor

      @NonNull <ApiType extends KubernetesObject> @NonNull SharedIndexInformer<ApiType> sharedIndexInformerFor(@NonNull @NonNull Class<ApiType> apiTypeClass, @Nullable @Nullable String namespace)
      Creates a new SharedIndexInformer.
      Type Parameters:
      ApiType - kubernetes api type
      Parameters:
      apiTypeClass - the api type class
      namespace - the namespace should be set to null for cluster-wide objects (e.g. V1Node) or for namespaced objects (e.g. V1Secret) when the informer needs to handle kubernetes objects from all namespaces
      Returns:
      instance of SharedIndexInformer
    • sharedIndexInformerFor

      @NonNull <ApiType extends KubernetesObject> @NonNull SharedIndexInformer<ApiType> sharedIndexInformerFor(@NonNull @NonNull Class<ApiType> apiTypeClass, @Nullable @Nullable String namespace, @Nullable @Nullable String labelSelector)
      Creates a new SharedIndexInformer.
      Type Parameters:
      ApiType - kubernetes api type
      Parameters:
      apiTypeClass - the api type class
      namespace - the namespace should be set to null for cluster-wide objects (e.g. V1Node) or for namespaced objects (e.g. V1Secret) when the informer needs to handle kubernetes objects from all namespaces
      labelSelector - the label selector
      Returns:
      instance of SharedIndexInformer
    • sharedIndexInformerFor

      @NonNull <ApiType extends KubernetesObject> @NonNull SharedIndexInformer<ApiType> sharedIndexInformerFor(@NonNull @NonNull Class<ApiType> apiTypeClass, @Nullable @Nullable String namespace, @Nullable @Nullable String labelSelector, long resyncPeriodMillis)
      Creates a new SharedIndexInformer.
      Type Parameters:
      ApiType - kubernetes api type
      Parameters:
      apiTypeClass - the api type class
      namespace - the namespace should be set to null for cluster-wide objects (e.g. V1Node) or for namespaced objects (e.g. V1Secret) when the informer needs to handle kubernetes objects from all namespaces
      labelSelector - the label selector
      resyncPeriodMillis - the resync period in milliseconds
      Returns:
      instance of SharedIndexInformer
    • sharedIndexInformerFor

      @NonNull <ApiType extends KubernetesObject> @NonNull SharedIndexInformer<ApiType> sharedIndexInformerFor(@NonNull @NonNull Class<ApiType> apiTypeClass, @Nullable @Nullable String namespace, @Nullable @Nullable String labelSelector, long resyncPeriodMillis, @Nullable @Nullable Function<ApiType,String> cacheKeyFunction, @Nullable @Nullable Map<String,Function<ApiType,List<String>>> cacheIndexFunctions)
      Creates a new SharedIndexInformer.
      Type Parameters:
      ApiType - api type
      Parameters:
      apiTypeClass - the api type class
      namespace - the namespace should be set to null for cluster-wide objects (e.g. V1Node) or for namespaced objects (e.g. V1Secret) when the informer needs to handle kubernetes objects from all namespaces
      labelSelector - the label selector
      resyncPeriodMillis - the resync period in milliseconds
      cacheKeyFunction - the function that is used to create cache key
      cacheIndexFunctions - the map of functions used to create indexes
      Returns:
      instance of SharedIndexInformer
    • sharedIndexInformersFor

      @NonNull <ApiType extends KubernetesObject> @NonNull List<SharedIndexInformer<ApiType>> sharedIndexInformersFor(@NonNull @NonNull Class<ApiType> apiTypeClass, @NonNull @NonNull List<String> namespaces, @Nullable @Nullable String labelSelector, long resyncPeriodMillis)
      Creates a new SharedIndexInformer for each namespace.
      Type Parameters:
      ApiType - kubernetes api type
      Parameters:
      apiTypeClass - the api type class
      namespaces - the list of namespaces
      labelSelector - the label selector
      resyncPeriodMillis - the resync period
      Returns:
      list of SharedIndexInformer instances. The order of informers in the returned list matches the order of namespaces in the input namespace list.
    • getExistingSharedIndexInformer

      @Nullable <ApiType extends KubernetesObject> @Nullable SharedIndexInformer<ApiType> getExistingSharedIndexInformer(@NonNull @NonNull Class<ApiType> apiTypeClass, @Nullable @Nullable String namespace)
      Returns already created SharedIndexInformer.
      Type Parameters:
      ApiType - api type
      Parameters:
      apiTypeClass - the api type class
      namespace - the namespace
      Returns:
      instance of SharedIndexInformer
    • startAllRegisteredInformers

      void startAllRegisteredInformers()
      Starts all registered informers.
    • stopAllRegisteredInformers

      void stopAllRegisteredInformers()
      Stops all registered informers.