Package

colossus.protocols

redis

Permalink

package redis

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. redis
  2. AnyRef
  3. Any
  1. Hide All
  2. Show all
Visibility
  1. Public
  2. All

Type Members

  1. trait BroadcastGather extends AnyRef

    Permalink
  2. case class BulkReply(data: ByteString) extends Reply with Product with Serializable

    Permalink
  3. case class Command(command: String, args: Seq[ByteString]) extends Product with Serializable

    Permalink

    The Command class allows us to do basic parsing and building with minimal overhead

  4. trait CommandHasher[T] extends AnyRef

    Permalink
  5. class DelScatterGather[T] extends ScatterGather[T]

    Permalink
  6. case class ErrorReply(message: String) extends MessageReply with Product with Serializable

    Permalink
  7. case class IntegerReply(value: Long) extends Reply with Product with Serializable

    Permalink
  8. case class MBulkReply(replies: Seq[Reply]) extends Reply with Product with Serializable

    Permalink
  9. class MGetScatterGather[T] extends ScatterGather[T]

    Permalink
  10. class MSetScatterGather[T] extends ScatterGather[T]

    Permalink
  11. sealed abstract class MessageReply extends Reply

    Permalink
  12. trait Redis extends Protocol

    Permalink
  13. trait RedisClient[M[_]] extends LiftedClient[Redis, M]

    Permalink

    This trait houses the Redis API.

    This trait houses the Redis API. It contains implementations for most(not all) commands. In particular, this trait makes a best attempt at providing all implementations for: - Key commands - String commands - Hash commands - List commands - Set commands - Zset commands

    Commands not implemented yet are

    • scan commands
    • 'admin' commands, ie commands which aren't directly related to a data type.

    Just because these commands are not implemented, doesn't mean they cannot be used. The implementors of this trait provide a generic 'execute' command, which allows for the execution of arbitrary colossus.protocols.redis.Commandobjects. The calling code is responsible for handling the raw colossus.protocols.redis.Reply.

    In some cases if a command can return an optional response(ie: a bulk reply or nil reply, like 'get'), 2 variants are provided. One which will return the data directly, and fail if its not there, and another which returns an Option. This is done to provide the user with some flexibility in how they query data. The point being, if you want to query and fail on non existence, you don't have to deal w/ an intermediate Option.

    No camelcase? Yea..camelcasing redis commands looked and felt weird. MGet? mGet? mget? mSetNx? msetNX? etc. So, since all redis commands are uppercased(at least in the docs), I went with all lower case for the API. I just wanted something consistent looking. The only camelcasing is for the functions which return options ie: getOption.

    This trait tries its best to be redis version agonstic. It doesn't know anything about the version of redis you are communicating with, so, for example, if an 'hstrlen' command is issued to a redis server that's < 3.2, you will get an Exception.

    Some commands(mainly zset commands) have additional arguments which alter its behavior. Instead of trying to capture all the argument combinations the function provides a varargs ByteString so that the user can provide whatever trailing flags or options they want. Each command which has this behavior is noted in its docs.

  14. class RedisClientCodec extends ClientCodec[Command, Reply]

    Permalink
  15. case class RedisException(message: String) extends Exception with Product with Serializable

    Permalink
  16. class RedisServerCodec extends ServerCodec[Command, Reply]

    Permalink
  17. sealed trait Reply extends AnyRef

    Permalink
  18. trait ScatterGather[T] extends AnyRef

    Permalink
  19. case class StatusReply(message: String) extends MessageReply with Product with Serializable

    Permalink
  20. case class UnexpectedRedisReplyException(message: String) extends Exception with Product with Serializable

    Permalink

Value Members

  1. object Command extends Serializable

    Permalink
  2. object EmptyMBulkReply extends Reply with Product with Serializable

    Permalink
  3. object NilMBulkReply extends Reply with Product with Serializable

    Permalink
  4. object NilReply extends Reply with Product with Serializable

    Permalink
  5. object RandomKeyBroadcastGather extends BroadcastGather

    Permalink
  6. object Redis extends ClientFactories[Redis, RedisClient]

    Permalink
  7. object RedisClient

    Permalink
  8. object RedisCommandParser

    Permalink
  9. object RedisReplyParser

    Permalink
  10. object ScatterGather

    Permalink
  11. object UnifiedBuilder

    Permalink
  12. object UnifiedProtocol

    Permalink

Inherited from AnyRef

Inherited from Any

Ungrouped