com.metamx.tranquility.druid.DruidBeams

Builder

class Builder[InputType, EventType] extends AnyRef

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Builder
  2. AnyRef
  3. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Value Members

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

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

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

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

    Definition Classes
    Any
  6. def alertMap(d: Dict): Builder[InputType, EventType]

    Provide extra information that will be emitted along with alerts.

    Provide extra information that will be emitted along with alerts. Optional, by default this is empty.

    d

    extra information

    returns

    new builder

  7. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  8. def beamDecorateFn(f: (org.scala_tools.time.Imports.Interval, Int) ⇒ (Beam[EventType]) ⇒ Beam[EventType]): Builder[InputType, EventType]

    Provide a function that decorates each per-partition, per-interval beam.

    Provide a function that decorates each per-partition, per-interval beam. Optional, by default there is no decoration. This is often used for gathering metrics.

    f

    function

    returns

    new builder

  9. def beamMergeFn(f: (Seq[Beam[EventType]]) ⇒ Beam[EventType]): Builder[InputType, EventType]

    Provide a function that merges beams for different partitions.

    Provide a function that merges beams for different partitions. Optional, by default this creates a com.metamx.tranquility.beam.MergingPartitioningBeam around your Builder.partitioner. You cannot provide both a beamMergeFn and a partitioner.

    f

    function

    returns

    new builder

  10. def buildBeam(): Beam[InputType]

    Build a Beam using this DruidBeams builder.

    Build a Beam using this DruidBeams builder.

    returns

    a beam

  11. def buildTranquilizer(builder: tranquilizer.Tranquilizer.Builder): Tranquilizer[InputType]

    Build a Tranquilizer using this DruidBeams builder.

    Build a Tranquilizer using this DruidBeams builder. This is a Finagle service, too, but unlike Builder.buildService and Builder.buildJavaService, it takes a single message at a time and does batching for you.

    builder

    a Tranquilizer builder with the desired configuration

    returns

    a service

  12. def buildTranquilizer(): Tranquilizer[InputType]

    Build a Tranquilizer using this DruidBeams builder.

    Build a Tranquilizer using this DruidBeams builder. This is a Finagle service, too, but unlike Builder.buildService and Builder.buildJavaService, it takes a single message at a time and does batching for you.

    returns

    a service

  13. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  14. def clusteredBeamIdent(ident: String): Builder[InputType, EventType]

    Provide the identity of this Beam, which will be used for coordination.

    Provide the identity of this Beam, which will be used for coordination. Optional, defaults to your overlord service discovery key + "/" + your dataSource.

    All beams with the same identity coordinate with each other on Druid tasks.

    ident

    ident string

    returns

    new builder

  15. def clusteredBeamZkBasePath(path: String): Builder[InputType, EventType]

    Provide the ZooKeeper znode that should be used for Tranquility's internal coordination.

    Provide the ZooKeeper znode that should be used for Tranquility's internal coordination. Optional, defaults to "/tranquility/beams".

    path

    the path

    returns

    new builder

  16. def curator(curator: CuratorFramework): Builder[InputType, EventType]

    Provide a CuratorFramework instance that will be used for Tranquility's internal coordination.

    Provide a CuratorFramework instance that will be used for Tranquility's internal coordination. Either this or "curatorFactory" is required. Whichever one is provided later will win.

    If you provide Curator this way (as opposed to "curatorFactory") then you should start and stop it yourself. You can safely share it across multiple builders.

    If you do not provide your own Builder.finagleRegistry, this will be used for service discovery as well.

    curator

    curator

    returns

    new builder

  17. def curatorFactory(curatorFactory: org.apache.curator.framework.CuratorFrameworkFactory.Builder): Builder[InputType, EventType]

    Provide a CuratorFrameworkFactory instance that will be used for Tranquility's internal coordination.

    Provide a CuratorFrameworkFactory instance that will be used for Tranquility's internal coordination. Either this or "curator" is required. Whichever one is provided later will win.

    If you provide Curator this way (as opposed to "curator") then the instance will be "owned" by this beam stack. This means that when you close the beams or tranquilizers returned by this builder, the Curator instance will be closed too.

    If you do not provide your own Builder.finagleRegistry, this will be used for service discovery as well.

    curatorFactory

    curator factory

    returns

    new builder

  18. def discoveryPath(path: String): Builder[InputType, EventType]

    Provide a znode used for Druid service discovery.

    Provide a znode used for Druid service discovery. Optional, defaults to "/druid/discovery".

    If you do not provide a Builder.finagleRegistry, this will be used along with your provided CuratorFramework to locate Druid services. If you do provide a FinagleRegistry, this option will not be used.

    path

    discovery znode

    returns

    new builder

  19. def druidBeamConfig(beamConfig: DruidBeamConfig): Builder[InputType, EventType]

    Provide tunings for communication with Druid tasks.

    Provide tunings for communication with Druid tasks. Optional, see DruidBeamConfig for defaults.

    beamConfig

    beam config tunings

    returns

    new builder

  20. def druidTuning(druidTuning: DruidTuning): Builder[InputType, EventType]

    Provide tunings for the Druid realtime engine.

    Provide tunings for the Druid realtime engine. Optional, see DruidTuning for defaults.

    These will be passed along to the Druid tasks.

    druidTuning

    tuning object

    returns

    new builder

  21. def druidTuningMap(druidTuningMap: Dict): Builder[InputType, EventType]

    Provide tunings for the Druid realtime engine.

    Provide tunings for the Druid realtime engine. Optional, see DruidTuning for defaults.

    These will be passed along to the Druid tasks.

    druidTuningMap

    tuning object, as a map

    returns

    new builder

  22. def emitter(emitter: ServiceEmitter): Builder[InputType, EventType]

    Provide an emitter that will be used to emit alerts.

    Provide an emitter that will be used to emit alerts. By default, alerts are emitted through a logger.

    emitter

    an emitter

    returns

    new builder

  23. final def eq(arg0: AnyRef): Boolean

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

    Definition Classes
    AnyRef → Any
  25. def eventTimestamped(timeFn: (EventType) ⇒ org.scala_tools.time.Imports.DateTime): Builder[InputType, EventType]

  26. def finagleRegistry(registry: FinagleRegistry): Builder[InputType, EventType]

    Provide a FinagleRegistry that will be used to generate clients for your Overlord.

    Provide a FinagleRegistry that will be used to generate clients for your Overlord. Optional, by default this is built based on Builder.curator and Builder.discoveryPath.

    registry

    a registry

    returns

    new builder

  27. def finalize(): Unit

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

    Definition Classes
    AnyRef → Any
  29. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  30. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  31. def location(location: DruidLocation): Builder[InputType, EventType]

    Provide the location of your Druid dataSource.

    Provide the location of your Druid dataSource. Required.

    This will be used to determine the service name of your Druid overlord and tasks, and to choose which dataSource to write to.

    location

    location object

    returns

    new builder

  32. final def ne(arg0: AnyRef): Boolean

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

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

    Definition Classes
    AnyRef
  35. def objectWriter(writer: JavaObjectWriter[EventType]): Builder[InputType, EventType]

    Provide a serializer for your event type.

    Provide a serializer for your event type. Optional, by default this uses a Jackson ObjectMapper.

    writer

    the serializer

    returns

    new builder

  36. def objectWriter(writer: ObjectWriter[EventType]): Builder[InputType, EventType]

    Provide a serializer for your event type.

    Provide a serializer for your event type. Optional, by default this uses a Jackson ObjectMapper.

    This method is designed use for Scala users.

    writer

    the serializer

    returns

    new builder

  37. def partitioner(partitioner: Partitioner[EventType]): Builder[InputType, EventType]

    Provide a partitioner that determines how to route events when you have more than one Druid partition.

    Provide a partitioner that determines how to route events when you have more than one Druid partition. By default this uses time-and-dimensions based partitioning for simple Map types, and uses hashCode for custom types. If you are using a custom type, you need to provide your own partitioner or beamMergeFn to get optimal rollup. You cannot provide both a beamMergeFn and a partitioner.

    partitioner

    a partitioner

    returns

    new builder

  38. def partitions(n: Int): Builder[InputType, EventType]

    Set the number of Druid partitions.

    Set the number of Druid partitions. This is just a helper method that modifies the Builder.tuning object.

    n

    number of partitions

    returns

    new builder

  39. def replicants(n: Int): Builder[InputType, EventType]

    Set the number of Druid replicants.

    Set the number of Druid replicants. This is just a helper method that modifies the Builder.tuning object.

    n

    number of replicants

    returns

    new builder

  40. def rollup(rollup: DruidRollup): Builder[InputType, EventType]

    Provide rollup (dimensions, aggregators, query granularity).

    Provide rollup (dimensions, aggregators, query granularity). Required.

    rollup

    rollup object

    returns

    new builder

  41. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  42. def timekeeper(timekeeper: Timekeeper): Builder[InputType, EventType]

    Provide a Timekeeper that will be used to determine what time it is for purposes of judging the windowPeriod.

    Provide a Timekeeper that will be used to determine what time it is for purposes of judging the windowPeriod. Optional, by default this uses wall clock time. This is mostly useful for tests, as in real-world use it is expected that you will be using wall clock time.

    timekeeper

    a timekeeper

    returns

    new builder

  43. def timestampSpec(timestampSpec: TimestampSpec): Builder[InputType, EventType]

    Provide a Druid timestampSpec.

    Provide a Druid timestampSpec. Optional, defaults to timestampColumn "timestamp" and timestampFormat "iso".

    Druid will use this to parse the timestamp of your serialized events.

    timestampSpec

    timestampSpec object

    returns

    new builder

  44. def toString(): String

    Definition Classes
    AnyRef → Any
  45. def tuning(tuning: ClusteredBeamTuning): Builder[InputType, EventType]

    Provide tunings for coordination of Druid task creation.

    Provide tunings for coordination of Druid task creation. Optional, see com.metamx.tranquility.beam.ClusteredBeamTuning$ for defaults.

    These influence how and when Druid tasks are created.

    tuning

    tuning object

    returns

    new builder

  46. final def wait(): Unit

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

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

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Deprecated Value Members

  1. def buildJavaService(): Service[List[InputType], Integer]

    Build a Finagle Service using this DruidBeams builder, designed for Java users.

    Build a Finagle Service using this DruidBeams builder, designed for Java users. This simply wraps the beam.

    returns

    a service

    Annotations
    @deprecated
    Deprecated

    (Since version 0.7.0) use buildTranquilizer

  2. def buildService(): Service[Seq[InputType], Int]

    Build a Finagle Service using this DruidBeams builder.

    Build a Finagle Service using this DruidBeams builder. This simply wraps the beam.

    returns

    a service

    Annotations
    @deprecated
    Deprecated

    (Since version 0.7.0) use buildTranquilizer

  3. def eventWriter(writer: ObjectWriter[EventType]): Builder[InputType, EventType]

    Annotations
    @deprecated
    Deprecated

    (Since version 0.2.21) use .objectWriter(...)

Inherited from AnyRef

Inherited from Any

Ungrouped