Class SubscriptionForwardingEndpointRegistry
java.lang.Object
org.springframework.data.redis.config.RedisListenerEndpointRegistry
org.springframework.data.redis.config.SubscriptionForwardingEndpointRegistry
- All Implemented Interfaces:
Lifecycle, Phased, SmartLifecycle
RedisListenerEndpointRegistry that notifies listener beans implementing SubscriptionListener once per
topic instead of once per registered endpoint.- Since:
- 4.2
- Author:
- Moritz Halbritter, Mark Paluch
-
Field Summary
Fields inherited from interface SmartLifecycle
DEFAULT_PHASE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidregisterListener(RedisListenerEndpoint endpoint, RedisMessageListenerContainer container) Register a newRedisListenerEndpointwith the givenRedisMessageListenerContainer.voidstart()voidstop()Methods inherited from class RedisListenerEndpointRegistry
getEndpoints, isRunningMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface SmartLifecycle
getPhase, isAutoStartup, isPauseable, stop
-
Constructor Details
-
SubscriptionForwardingEndpointRegistry
public SubscriptionForwardingEndpointRegistry()
-
-
Method Details
-
registerListener
public void registerListener(RedisListenerEndpoint endpoint, RedisMessageListenerContainer container) Description copied from class:RedisListenerEndpointRegistryRegister a newRedisListenerEndpointwith the givenRedisMessageListenerContainer.- Overrides:
registerListenerin classRedisListenerEndpointRegistry- Parameters:
endpoint- the endpoint to register.container- the container to register the endpoint with.
-
start
public void start()- Specified by:
startin interfaceLifecycle- Overrides:
startin classRedisListenerEndpointRegistry
-
stop
public void stop()- Specified by:
stopin interfaceLifecycle- Overrides:
stopin classRedisListenerEndpointRegistry
-