Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitElasticSearchSink ¶
func InitSinkDriver ¶
Types ¶
type ElasticSearchSink ¶
func GetElasticSearchSink ¶
func GetElasticSearchSink() *ElasticSearchSink
func NewElasticSearchSink ¶
func NewElasticSearchSink(opts map[string]string) (*ElasticSearchSink, error)
func (*ElasticSearchSink) WriteEvents ¶
func (es *ElasticSearchSink) WriteEvents(events []*types.Event) error
type KafkaSink ¶
type KafkaSink struct { Brokers string Topic string Producer sarama.AsyncProducer }
type OpentsdbSink ¶
type OpentsdbSink struct {
Endpoint string
}
func (*OpentsdbSink) Write ¶
func (opentsdb *OpentsdbSink) Write(metrics *types.MetricPayload) error
Write points to opentsdb. http://opentsdb.net/docs/build/html/api_http/put.html Data points: [
{ "metric": "sys.cpu.nice", "timestamp": 1346846400, "value": 18, "tags": { "host": "web01", "dc": "lga" } }, { "metric": "sys.cpu.nice", "timestamp": 1346846400, "value": 9, "tags": { "host": "web02", "dc": "lga" } }
]
type SinkDriver ¶
type SinkDriver interface {
Write(*types.MetricPayload) error
}
func GetSinkDriver ¶
func GetSinkDriver() SinkDriver
func NewKafkaSink ¶
func NewKafkaSink(opts map[string]string) (SinkDriver, error)
func NewOpentsdbSink ¶
func NewOpentsdbSink(opts map[string]string) (SinkDriver, error)
Click to show internal directories.
Click to hide internal directories.