com.metamx.tranquility.druid.DruidBeams
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.
extra information
new builder
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.
function
new builder
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.
function
new builder
Build a Beam using this DruidBeams builder.
Build a Beam using this DruidBeams builder.
a beam
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.
a Tranquilizer builder with the desired configuration
a service
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.
a service
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 string
new builder
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".
the path
new builder
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
new builder
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.
curator factory
new builder
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.
discovery znode
new builder
Provide tunings for communication with Druid tasks.
Provide tunings for communication with Druid tasks. Optional, see DruidBeamConfig for defaults.
beam config tunings
new builder
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.
tuning object
new builder
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.
tuning object, as a map
new builder
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.
an emitter
new builder
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.
a registry
new builder
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 object
new builder
Provide a serializer for your event type.
Provide a serializer for your event type. Optional, by default this uses a Jackson ObjectMapper.
the serializer
new builder
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.
the serializer
new builder
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.
a partitioner
new builder
Set the number of Druid partitions.
Set the number of Druid partitions. This is just a helper method that modifies the Builder.tuning object.
number of partitions
new builder
Set the number of Druid replicants.
Set the number of Druid replicants. This is just a helper method that modifies the Builder.tuning object.
number of replicants
new builder
Provide rollup (dimensions, aggregators, query granularity).
Provide rollup (dimensions, aggregators, query granularity). Required.
rollup object
new builder
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.
a timekeeper
new builder
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 object
new builder
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 object
new builder
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.
a service
(Since version 0.7.0) use buildTranquilizer
Build a Finagle Service using this DruidBeams builder.
Build a Finagle Service using this DruidBeams builder. This simply wraps the beam.
a service
(Since version 0.7.0) use buildTranquilizer
(Since version 0.2.21) use .objectWriter(...)