Package

com.metamx.tranquility

tranquilizer

Permalink

package tranquilizer

Visibility
  1. Public
  2. All

Type Members

  1. class BufferFullException extends Exception

    Permalink

    Exception indicating that the outgoing buffer was full.

    Exception indicating that the outgoing buffer was full. Will only be thrown if "blockOnFull" is false.

  2. class MessageDroppedException extends Exception with NoStacktrace

    Permalink

    Exception indicating that a message was dropped "on purpose" by the beam.

    Exception indicating that a message was dropped "on purpose" by the beam. This is not a recoverable exception and so the message must be discarded.

  3. class SimpleTranquilizerAdapter[MessageType] extends Logging

    Permalink

    Wrap a Tranquilizer, exposing an API that is meant to be easy to use for a single caller that doesn't care exactly what happens with individual messages, but does care about having exceptions and counts reported eventually.

    Wrap a Tranquilizer, exposing an API that is meant to be easy to use for a single caller that doesn't care exactly what happens with individual messages, but does care about having exceptions and counts reported eventually.

    Exceptions are reported from time to time when you call "send", and always when you call "flush". Only one exception will be reported at a time. Note that exceptions triggered by "send" may not necessarily be related to the actual message you passed; they could be from a previous message.

    The expected use case of the simple adapter is that if you get an exception from "send" or "flush", you should stop using the adapter and create a new one. It is not meant to make it possible to associate specific exceptions with specific messages.

    Calling "start" or "stop" on this adapter will start or stop the underlying Tranquilizer. If you want to start or stop the underlying Tranquilizer yourself, then do not call "start" or "stop" on this adapter.

    The expected use case of this class is that it is used by a single thread.

  4. class Tranquilizer[MessageType] extends Service[MessageType, Unit] with Logging

    Permalink

    Tranquilizers allow you to provide single messages and get a future for each message reporting success or failure.

    Tranquilizers allow you to provide single messages and get a future for each message reporting success or failure. Tranquilizers provide batching and backpressure, unlike Beams which require you to batch messages on your own and do not provide backpressure.

    The expected use case of this class is to send individual messages efficiently, possibly from multiple threads, and receive success or failure information for each message. This class is thread-safe.

    To create Tranquilizers, use Tranquilizer$.create, Tranquilizer$.builder, or com.metamx.tranquility.druid.DruidBeams$$Builder#buildTranquilizer.

Value Members

  1. object MessageDroppedException extends Serializable

    Permalink
  2. object SimpleTranquilizerAdapter

    Permalink
  3. object Tranquilizer

    Permalink

Ungrouped