Package org.redisson.api
Interface RPatternTopicReactive<M>
-
- Type Parameters:
M
- the type of message object
- All Known Implementing Classes:
RedissonPatternTopicReactive
public interface RPatternTopicReactive<M>
Distributed topic. Messages are delivered to all message listeners across Redis cluster.- Author:
- Nikita Koksharov
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description org.reactivestreams.Publisher<Integer>
addListener(PatternMessageListener<M> listener)
Subscribes to this topic.org.reactivestreams.Publisher<Integer>
addListener(PatternStatusListener listener)
Subscribes to status changes of this topicList<String>
getPatternNames()
Get topic channel patternsvoid
removeListener(int listenerId)
Removes the listener byid
for listening this topic
-
-
-
Method Detail
-
getPatternNames
List<String> getPatternNames()
Get topic channel patterns- Returns:
- list of topic names
-
addListener
org.reactivestreams.Publisher<Integer> addListener(PatternMessageListener<M> listener)
Subscribes to this topic.MessageListener.onMessage
is called when any message is published on this topic.- Parameters:
listener
- - message listener- Returns:
- local JVM unique listener id
- See Also:
MessageListener
-
addListener
org.reactivestreams.Publisher<Integer> addListener(PatternStatusListener listener)
Subscribes to status changes of this topic- Parameters:
listener
- - message listener- Returns:
- local JVM unique listener id
- See Also:
StatusListener
-
removeListener
void removeListener(int listenerId)
Removes the listener byid
for listening this topic- Parameters:
listenerId
- - message listener id
-
-