Class SharedProcessor<ApiType extends io.kubernetes.client.common.KubernetesObject>
java.lang.Object
io.kubernetes.client.informer.cache.SharedProcessor<ApiType>
public class SharedProcessor<ApiType extends io.kubernetes.client.common.KubernetesObject>
extends Object
-
Constructor Summary
ConstructorsConstructorDescriptionSharedProcessor(ExecutorService threadPool) SharedProcessor(ExecutorService threadPool, Duration timeout) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddAndStartListener(ProcessorListener<ApiType> processorListener) addAndStartListener first adds the specific processorListener then starts the listener with executor.voidaddListener(ProcessorListener<ApiType> processorListener) addListener adds the specific processorListener, but not start it.voiddistribute(ProcessorListener.Notification<ApiType> obj, boolean isSync) distribute the object among listeners.voidrun()starts the processor listeners.booleanvoidstop()
-
Constructor Details
-
SharedProcessor
public SharedProcessor() -
SharedProcessor
-
SharedProcessor
-
-
Method Details
-
addAndStartListener
addAndStartListener first adds the specific processorListener then starts the listener with executor.- Parameters:
processorListener- specific processor listener
-
addListener
addListener adds the specific processorListener, but not start it.- Parameters:
processorListener- specific processor listener
-
run
public void run()starts the processor listeners. -
distribute
distribute the object among listeners.- Parameters:
obj- specific objisSync- is sync or not
-
shouldResync
public boolean shouldResync() -
stop
public void stop()
-