Last active
May 19, 2016 09:36
-
-
Save xeago/a6360914ceb2a80555bc18efaf6ba80f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
commit c251b8fb2c30d767f3eac253c645e2325c941473 | |
Author: Twan Wolthof <xeago@spotify.com> | |
Date: Thu May 19 09:05:20 2016 +0000 | |
wip | |
diff --git a/build.gradle b/build.gradle | |
index d718c40..2285d50 100644 | |
--- a/build.gradle | |
+++ b/build.gradle | |
@@ -80,6 +80,7 @@ dependencies { | |
compile 'args4j:args4j:2.0.25' | |
compile 'com.google.cloud.bigtable:bigtable-hbase-1.1:0.3.0' | |
compile 'org.apache.hbase:hbase-client:1.2.1' | |
+ compile 'com.spotify.metrics:semantic-metrics-core:0.5.1' | |
compile group: 'io.netty', name: 'netty-tcnative', version: '1.1.33.Fork13', classifier: classifier | |
compile 'com.fasterxml.jackson.core:jackson-databind:2.6.1' | |
testCompile group: 'junit', name: 'junit', version: '4.10' | |
diff --git a/src/main/java/com/netflix/bdp/s3mper/alert/impl/SemanticMetricsDispatcher.java b/src/main/java/com/netflix/bdp/s3mper/alert/impl/SemanticMetricsDispatcher.java | |
new file mode 100644 | |
index 0000000..0ba7c75 | |
--- /dev/null | |
+++ b/src/main/java/com/netflix/bdp/s3mper/alert/impl/SemanticMetricsDispatcher.java | |
@@ -0,0 +1,48 @@ | |
+package com.netflix.bdp.s3mper.alert.impl; | |
+ | |
+import com.netflix.bdp.s3mper.alert.AlertDispatcher; | |
+import com.spotify.metrics.core; | |
+import org.apache.hadoop.conf.Configuration; | |
+import org.apache.hadoop.fs.Path; | |
+ | |
+import java.net.URI; | |
+import java.util.List; | |
+ | |
+public class SemanticMetricsDispatcher implements AlertDispatcher{ | |
+ | |
+ private final SemanticMetricRegistry registry; | |
+ | |
+ private final Meter request; | |
+ | |
+ public SemanticMetricsDispatcher(SemanticMetricRegistry registry) { | |
+ this.registry = registry; | |
+ this.request = registry.meter(MetricId.build().tagged( | |
+ "what", "requests", "unit", "request")); | |
+ } | |
+ | |
+ | |
+ @Override | |
+ public void alert(List<Path> paths) { | |
+ | |
+ } | |
+ | |
+ @Override | |
+ public void timeout(String operation, List<Path> paths) { | |
+ | |
+ } | |
+ | |
+ @Override | |
+ public void init(URI uri, Configuration conf) { | |
+ | |
+ } | |
+ | |
+ @Override | |
+ public void setConfig(Configuration conf) { | |
+ | |
+ } | |
+ | |
+ @Override | |
+ public void recovered(List<Path> paths) { | |
+ | |
+ } | |
+} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment