com.twitter.finagle

failters

package failters

Visibility
  1. Public
  2. All

Type Members

  1. case class Blackholeter[Req, Rep](probability: Var[Double], seed: Long = Failter.DefaultSeed, stats: StatsReceiver = NullStatsReceiver) extends SimpleFilter[Req, Rep] with Failter with Product with Serializable

    A blackholeter rejects/fails by returning a promise from a service which will never be fulfilled.

    A blackholeter rejects/fails by returning a promise from a service which will never be fulfilled.

    This is useful for testing timeout response. Note that the underlying service is NOT called in this variant.

    probability

    [0,1], where 1 is 100% blackhole mode

  2. case class ByzantineBlackholeter[Req, Rep](probability: Var[Double], seed: Long = Failter.DefaultSeed, stats: StatsReceiver = NullStatsReceiver) extends SimpleFilter[Req, Rep] with Failter with Product with Serializable

    A blackholeter rejects/fails by returning a promise from a service which will never be fulfilled.

    A blackholeter rejects/fails by returning a promise from a service which will never be fulfilled.

    This is useful for testing timeout response. Note that the underlying service IS called in this variant, but the result is DISCARDED. Useful for checking for idempotent behavior.

    probability

    [0,1] whre 1 is 100% blackhole mode

  3. case class ByzantineRejectFailter[Req, Rep](probability: Var[Double], rejectWith: () ⇒ Throwable = ..., seed: Long = Failter.DefaultSeed, stats: StatsReceiver = NullStatsReceiver) extends SimpleFilter[Req, Rep] with Failter with Product with Serializable

    Like the reject filter, but will throw exceptions AFTER the service has been called.

  4. trait Failter extends AnyRef

  5. case class RejectFailter[Req, Rep](probability: Var[Double], rejectWith: () ⇒ Throwable = ..., seed: Long = Failter.DefaultSeed, stats: StatsReceiver = NullStatsReceiver) extends SimpleFilter[Req, Rep] with Failter with Product with Serializable

    Randomly creates a Future.exception with the specified exception class before calling downstream filters and services.

    Randomly creates a Future.exception with the specified exception class before calling downstream filters and services. Probability is in [0,1] where 0 means no failures.

    probability
    rejectWith

    A class to reject with. Must have a no-arguments constructor.

    seed

    A random seed, otherwise a deterministic seed is used.

Value Members

  1. object Failter

Ungrouped