Module lettuce.core

Interface NodeSelectionPubSubCommands<K,​V>


public interface NodeSelectionPubSubCommands<K,​V>
Synchronous executed commands on a node selection for Pub/Sub.
Since:
4.4
Author:
Mark Paluch
  • Method Summary

    Modifier and Type Method Description
    Executions<Void> psubscribe​(K... patterns)
    Listen for messages published to channels matching the given patterns.
    Executions<Void> punsubscribe​(K... patterns)
    Stop listening for messages posted to channels matching the given patterns.
    Executions<Void> subscribe​(K... channels)
    Listen for messages published to the given channels.
    Executions<Void> unsubscribe​(K... channels)
    Stop listening for messages posted to the given channels.
  • Method Details

    • psubscribe

      Executions<Void> psubscribe​(K... patterns)
      Listen for messages published to channels matching the given patterns.
      Parameters:
      patterns - the patterns
      Returns:
      Executions to synchronize psubscribe completion
    • punsubscribe

      Executions<Void> punsubscribe​(K... patterns)
      Stop listening for messages posted to channels matching the given patterns.
      Parameters:
      patterns - the patterns
      Returns:
      Executions Future to synchronize punsubscribe completion
    • subscribe

      Executions<Void> subscribe​(K... channels)
      Listen for messages published to the given channels.
      Parameters:
      channels - the channels
      Returns:
      Executions Future to synchronize subscribe completion
    • unsubscribe

      Executions<Void> unsubscribe​(K... channels)
      Stop listening for messages posted to the given channels.
      Parameters:
      channels - the channels
      Returns:
      Executions Future to synchronize unsubscribe completion.