sentry2prometheus

command module
v0.0.0-...-3231cb8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 5, 2019 License: MIT Imports: 10 Imported by: 0

README

Sentry Errors Prometheus Exporter

Go Report Card

./sentry2prometheus --help

Usage of ./sentry2prometheus:
      --extra-labels strings   Extra labels for prometheus metrics splitted by ':'
      --organization string    Organization name in sentry (default "XXX")
      --port string            The address to listen on for HTTP requests. (default ":9412")
      --query string           Sentry query for projects filtering
      --sentry-url string      The sentry url (default "https://sentry.io")
      --stats-period string    Sentry stats period (default "24h")
      --token string           Sentry API authorization token

Build

Work with 1.12 and modules

go build

Usage Example

Take sentry token from https://sentry.io/api

./sentry2prometheus --sentry-url=https://sentry.io \
    --organization=XXX \
    --query=team:web \
    --token=token_from_sentry \
    --extra-labels=team:web,one:1,two:2

Visiting http://localhost:9412/ will return metrics for a the sentry projects in your organization filtered by query

# HELP probe_sentry_errors_received Errors count since timestamp
# TYPE probe_sentry_errors_received counter
probe_sentry_errors_received{project="portal", timestamp=1560322800, team="web"} 5
probe_success 1
probe_projects_count 1
probe_duration_seconds 0.132

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL