scredis

BlockingClient

final class BlockingClient extends AkkaBlockingConnection with BlockingListCommands

Defines a Redis client supporting all blocking commands.

Linear Supertypes
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. BlockingClient
  2. BlockingListCommands
  3. AkkaBlockingConnection
  4. BlockingConnection
  5. AbstractAkkaConnection
  6. LazyLogging
  7. Logging
  8. Connection
  9. AnyRef
  10. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new BlockingClient(configName: String, path: String)(implicit system: ActorSystem)

    Constructs a scredis.BlockingClient instance from a config file and using the provided path.

    Constructs a scredis.BlockingClient instance from a config file and using the provided path.

    configName

    config filename

    path

    path pointing to the scredis config object

    returns

    the constructed scredis.BlockingClient

    Note

    The path must include to the scredis object, e.g. x.y.scredis

  2. new BlockingClient(configName: String)(implicit system: ActorSystem)

    Constructs a scredis.BlockingClient instance from a config file.

    Constructs a scredis.BlockingClient instance from a config file.

    configName

    config filename

    returns

    the constructed scredis.BlockingClient

    Note

    The config file must contain the scredis object at its root. This constructor is equivalent to

    new Client(configName, "scredis")
  3. new BlockingClient(config: Config)(implicit system: ActorSystem)

    Constructs a scredis.BlockingClient instance from a com.typesafe.Config

    Constructs a scredis.BlockingClient instance from a com.typesafe.Config

    config

    com.typesafe.Config

    returns

    the constructed scredis.BlockingClient

    Note

    The config must contain the scredis object at its root. This constructor is equivalent to

    new Client(config, "scredis")
  4. new BlockingClient(config: RedisConfig)(implicit system: ActorSystem)

    Constructs a scredis.BlockingClient instance from a scredis.RedisConfig

    Constructs a scredis.BlockingClient instance from a scredis.RedisConfig

    config

    scredis.RedisConfig

    returns

    the constructed scredis.BlockingClient

  5. new BlockingClient(host: String = RedisConfigDefaults.Redis.Host, port: Int = RedisConfigDefaults.Redis.Port, passwordOpt: Option[String] = ..., database: Int = RedisConfigDefaults.Redis.Database, nameOpt: Option[String] = RedisConfigDefaults.Redis.NameOpt, connectTimeout: FiniteDuration = ..., maxWriteBatchSize: Int = ..., tcpSendBufferSizeHint: Int = ..., tcpReceiveBufferSizeHint: Int = ..., akkaListenerDispatcherPath: String = ..., akkaIODispatcherPath: String = ..., akkaDecoderDispatcherPath: String = ...)(implicit system: ActorSystem)

    host

    server address

    port

    server port

    passwordOpt

    optional server password

    database

    database index to select

    nameOpt

    optional client name (available since 2.6.9)

    connectTimeout

    connection timeout

    maxWriteBatchSize

    max number of bytes to send as part of a batch

    tcpSendBufferSizeHint

    size hint of the tcp send buffer, in bytes

    tcpReceiveBufferSizeHint

    size hint of the tcp receive buffer, in bytes

    akkaListenerDispatcherPath

    path to listener dispatcher definition

    akkaIODispatcherPath

    path to io dispatcher definition

    akkaDecoderDispatcherPath

    path to decoder dispatcher definition

Value Members

  1. final def !=(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  4. val akkaDecoderDispatcherPath: String

    Attributes
    protected
    Definition Classes
    AbstractAkkaConnection
  5. val akkaIODispatcherPath: String

    Attributes
    protected
    Definition Classes
    AbstractAkkaConnection
  6. val akkaListenerDispatcherPath: String

    Attributes
    protected
    Definition Classes
    AbstractAkkaConnection
  7. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  8. def auth(password: String)(implicit timeout: Duration): Try[Unit]

    Authenticates to the server.

    Authenticates to the server.

    password

    the server password

    Since

    1.0.0

    Exceptions thrown
    [[scredis.exceptions.RedisErrorResponseException]]

    if authentication failed

  9. def blPop[R](timeoutSeconds: Int, keys: String*)(implicit arg0: Reader[R]): Try[Option[(String, R)]]

    Removes and returns the first element in a list, or block until one is available.

    Removes and returns the first element in a list, or block until one is available.

    timeoutSeconds

    timeout in seconds, if zero, the command blocks indefinitely until an element is available

    keys

    list key(s)

    returns

    list of key to popped element pair, or None if timeout occurs

    Definition Classes
    BlockingListCommands
    Since

    2.0.0

    Exceptions thrown
    [[scredis.exceptions.RedisErrorResponseException]]

    if a key contains a non-list value

  10. def brPop[R](timeoutSeconds: Int, keys: String*)(implicit arg0: Reader[R]): Try[Option[(String, R)]]

    Removes and returns the last element in a list, or block until one is available.

    Removes and returns the last element in a list, or block until one is available.

    timeoutSeconds

    timeout in seconds, if zero, the command blocks indefinitely until an element is available in at least one of the provided lists

    keys

    list key(s)

    returns

    list of key to popped element pair, or None if timeout occurs

    Definition Classes
    BlockingListCommands
    Since

    2.0.0

    Exceptions thrown
    [[scredis.exceptions.RedisErrorResponseException]]

    if a key contains a non-list value

  11. def brPopLPush[R](sourceKey: String, destKey: String, timeoutSeconds: Int)(implicit arg0: Reader[R]): Try[Option[R]]

    Pops a value from a list, pushes it to another list and returns it, or block until one is available.

    Pops a value from a list, pushes it to another list and returns it, or block until one is available.

    sourceKey

    key of list to pop from

    destKey

    key of list to push to

    timeoutSeconds

    timeout in seconds, if zero, the command blocks indefinitely until an element is available in the list at sourceKey

    returns

    the element being popped from source and pushed to destination, or None if timeout occurs

    Definition Classes
    BlockingListCommands
    Since

    2.2.0

    Exceptions thrown
    [[scredis.exceptions.RedisErrorResponseException]]

    if sourceKey or destKey contain non-list values

  12. def clientSetName(name: String)(implicit timeout: Duration): Try[Unit]

    Sets the current client name.

    Sets the current client name. If the empty string is provided, the name will be unset.

    name

    name to associate the client to, if empty, unsets the client name

    Since

    2.6.9

  13. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  14. val connectTimeout: FiniteDuration

    Attributes
    protected
    Definition Classes
    AbstractAkkaConnection
  15. var database: Int

    Attributes
    protected
    Definition Classes
    AbstractAkkaConnection
  16. val decodersCount: Int

    Attributes
    protected
    Definition Classes
    AbstractAkkaConnection
  17. implicit val dispatcher: ExecutionContextExecutor

    Definition Classes
    AbstractAkkaConnectionConnection
  18. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  19. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  20. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  21. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  22. def getDatabase: Int

    Attributes
    protected
    Definition Classes
    AbstractAkkaConnection
  23. def getNameOpt: Option[String]

    Attributes
    protected
    Definition Classes
    AbstractAkkaConnection
  24. def getPasswordOpt: Option[String]

    Attributes
    protected
    Definition Classes
    AbstractAkkaConnection
  25. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  26. val host: String

    Attributes
    protected
    Definition Classes
    AbstractAkkaConnection
  27. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  28. var isShuttingDown: Boolean

    Attributes
    protected
    Definition Classes
    AbstractAkkaConnection
  29. implicit val listenerActor: ActorRef

    Attributes
    protected
    Definition Classes
    AkkaBlockingConnection
  30. lazy val logger: Logger

    Attributes
    protected
    Definition Classes
    LazyLogging → Logging
  31. val maxWriteBatchSize: Int

    Attributes
    protected
    Definition Classes
    AbstractAkkaConnection
  32. var nameOpt: Option[String]

    Attributes
    protected
    Definition Classes
    AbstractAkkaConnection
  33. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  34. final def notify(): Unit

    Definition Classes
    AnyRef
  35. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  36. var passwordOpt: Option[String]

    Attributes
    protected
    Definition Classes
    AbstractAkkaConnection
  37. val port: Int

    Attributes
    protected
    Definition Classes
    AbstractAkkaConnection
  38. def quit()(implicit timeout: Duration): Try[Unit]

    Closes the connection.

    Closes the connection.

    Since

    1.0.0

  39. val receiveTimeoutOpt: Option[FiniteDuration]

    Attributes
    protected
    Definition Classes
    AbstractAkkaConnection
  40. def select(database: Int)(implicit timeout: Duration): Try[Unit]

    Changes the selected database on the current client.

    Changes the selected database on the current client.

    Since

    1.0.0

    Exceptions thrown
    [[scredis.exceptions.RedisErrorResponseException]]

    if the database index is invalid

  41. def sendBlocking[A](request: Request[A])(implicit timeout: Duration): Try[A]

    Attributes
    protected
    Definition Classes
    AkkaBlockingConnectionBlockingConnection
  42. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  43. val system: ActorSystem

    Attributes
    protected
    Definition Classes
    AbstractAkkaConnection
  44. val tcpReceiveBufferSizeHint: Int

    Attributes
    protected
    Definition Classes
    AbstractAkkaConnection
  45. val tcpSendBufferSizeHint: Int

    Attributes
    protected
    Definition Classes
    AbstractAkkaConnection
  46. def toString(): String

    Definition Classes
    AnyRef → Any
  47. def updateState(request: Request[_]): Unit

    Attributes
    protected
    Definition Classes
    AbstractAkkaConnection
  48. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  49. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  50. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from BlockingListCommands

Inherited from AkkaBlockingConnection

Inherited from BlockingConnection

Inherited from AbstractAkkaConnection

Inherited from LazyLogging

Inherited from Logging

Inherited from Connection

Inherited from AnyRef

Inherited from Any

Ungrouped