Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Skyline.analyzer.metrics #2

Merged
merged 2 commits into from
Dec 29, 2014
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions src/analyzer/analyzer.py
Original file line number Diff line number Diff line change
Expand Up @@ -221,6 +221,14 @@ def run(self):
# Log to Graphite
self.send_graphite_metric('skyline.analyzer.run_time', '%.2f' % (time() - now))
self.send_graphite_metric('skyline.analyzer.total_analyzed', '%.2f' % (len(unique_metrics) - sum(exceptions.values())))
self.send_graphite_metric('skyline.analyzer.total_anomalies', '%d' % len(self.anomalous_metrics))
self.send_graphite_metric('skyline.analyzer.total_metrics', '%d' % len(unique_metrics))
for key, value in exceptions.items():
send_metric = 'skyline.analyzer.exceptions.%s' % key
self.send_graphite_metric(send_metric, '%d' % value)
for key, value in anomaly_breakdown.items():
send_metric = 'skyline.analyzer.anomaly_breakdown.%s' % key
self.send_graphite_metric(send_metric, '%d' % value)

# Check canary metric
raw_series = self.redis_conn.get(settings.FULL_NAMESPACE + settings.CANARY_METRIC)
Expand Down
5 changes: 4 additions & 1 deletion src/settings.py.example
Original file line number Diff line number Diff line change
Expand Up @@ -209,8 +209,11 @@ MAX_RESOLUTION = 1000
# in Skyline. The Listener will check to see if each incoming metrics
# contains anything in the skip list. It is generally wise to skip entire
# namespaces by adding a '.' at the end of the skipped item - otherwise
# you might skip things you don't intend to.
# you might skip things you don't intend to. For example the default
# skyline.analyzer.anomaly_breakdown. which MUST be skipped to prevent crazy
# feedback.
SKIP_LIST = [
'skyline.analyzer.anomaly_breakdown.',
'example.statsd.metric',
'another.example.metric',
# if you use statsd, these can result in many near-equal series
Expand Down