Skip to content
Open source framework for processing, monitoring, and alerting on time series data
Go Python Shell
Branch: master
Clone or download

Latest commit

Latest commit 28b69c1 Apr 21, 2020

Files

Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.circleci
.github
.hooks
alert
auth
bufpool
client fix(http): use default transport consitently Mar 11, 2019
clock
cmd
command
edge
etc
examples Add example of all nodes in load tasks style dir Oct 17, 2017
expvar
http
influxdb
integrations
keyvalue
listmap
models
pipeline chore(go): update to Go 1.13 Jan 10, 2020
scripts
server
services
tick
timer
tlsconfig
udf
usr/share/bash-completion/completions
uuid
vendor
waiter
.dockerignore
.gitattributes
.gitignore
BLOB_STORE_DESIGN.md
CHANGELOG.md
CONTRIBUTING.md
DESIGN.md
Dockerfile_build_ubuntu32
Dockerfile_build_ubuntu64
Gopkg.lock
Gopkg.toml
LICENSE
LICENSE_OF_DEPENDENCIES.md
README.md
alert.go
autoscale.go
barrier.go
batch.go
build.py
build.sh
change_detect.go
circle-test.sh
circle.yml
combine.go
combine_test.go
default.go
delete.go
derivative.go
doc.go
edge.go
eval.go
expr.go
flatten.go
gobuild.sh
group_by.go
http_out.go
http_post.go
influxdb_out.go
influxql.gen.go
influxql.gen.go.tmpl
influxql.go
join.go
kapacitor_loopback.go
list-deps
log.go
metaclient.go
node.go
noop.go
output.go
query.go
query_test.go
replay.go
result.go
sample.go
shift.go
sideload.go
state_tracking.go
stats.go
stream.go
task.go
task_master.go
template.go
test.sh
tickdoc.conf
tmpldata.json
udf.go
udf_test.go
union.go
update_tick_docs.sh
where.go
window.go
window_test.go

README.md

Kapacitor Circle CI Docker pulls

Open source framework for processing, monitoring, and alerting on time series data

Installation

Kapacitor has two binaries:

  • kapacitor – a CLI program for calling the Kapacitor API.
  • kapacitord – the Kapacitor server daemon.

You can either download the binaries directly from the downloads page or go get them:

go get github.com/influxdata/kapacitor/cmd/kapacitor
go get github.com/influxdata/kapacitor/cmd/kapacitord

Configuration

An example configuration file can be found here

Kapacitor can also provide an example config for you using this command:

kapacitord config

Getting Started

This README gives you a high level overview of what Kapacitor is and what its like to use it. As well as some details of how it works. To get started using Kapacitor see this guide. After you finish the getting started exercise you can check out the TICKscripts for different Telegraf plugins.

Basic Example

Kapacitor uses a DSL named TICKscript to define tasks.

A simple TICKscript that alerts on high cpu usage looks like this:

stream
    |from()
        .measurement('cpu_usage_idle')
        .groupBy('host')
    |window()
        .period(1m)
        .every(1m)
    |mean('value')
    |eval(lambda: 100.0 - "mean")
        .as('used')
    |alert()
        .message('{{ .Level}}: {{ .Name }}/{{ index .Tags "host" }} has high cpu usage: {{ index .Fields "used" }}')
        .warn(lambda: "used" > 70.0)
        .crit(lambda: "used" > 85.0)

        // Send alert to hander of choice.

        // Slack
        .slack()
        .channel('#alerts')

        // VictorOps
        .victorOps()
        .routingKey('team_rocket')

        // PagerDuty
        .pagerDuty()

Place the above script into a file cpu_alert.tick then run these commands to start the task:

# Define the task (assumes cpu data is in db 'telegraf')
kapacitor define \
    cpu_alert \
    -type stream \
    -dbrp telegraf.default \
    -tick ./cpu_alert.tick
# Start the task
kapacitor enable cpu_alert

For more complete examples see the documentation.

You can’t perform that action at this time.