Commit 629654aa by Amir Aharon

downgrade metrics-influxdb to match iot's jar

parent bebbfb0f
### Microservice Framework in JAVA ### Microservice Framework in JAVA
## 2.1.1
- downgrade metrics influxdb to fit the reporter on iot jar
## 2.1.0 ## 2.1.0
- Add MsgQueue Service for ZMQ - Add MsgQueue Service for ZMQ
## 2.0.1 add /_mon/_apiList to get all rest api's and add influxdb metrics ## 2.0.1 add /_mon/_apiList to get all rest api's and add influxdb metrics
......
group 'com.ipgallery.common' group 'com.ipgallery.common'
version '2.1.0' version '2.1.1'
apply plugin: 'java' apply plugin: 'java'
apply plugin: 'maven-publish' apply plugin: 'maven-publish'
...@@ -29,7 +29,8 @@ dependencies { ...@@ -29,7 +29,8 @@ dependencies {
compile 'com.ipgallery.common:utils:1.2.5' compile 'com.ipgallery.common:utils:1.2.5'
compile ('com.ipgallery.common:rabbitmq:1.0.3') compile ('com.ipgallery.common:rabbitmq:1.0.3')
compile 'com.ecwid.consul:consul-api:1.1.9' compile 'com.ecwid.consul:consul-api:1.1.9'
compile 'com.github.davidb:metrics-influxdb:0.9.3' //compile 'com.github.davidb:metrics-influxdb:0.9.3'
compile 'com.github.davidb:metrics-influxdb:0.8.2'
compile 'io.dropwizard.metrics:metrics-graphite:3.2.5' compile 'io.dropwizard.metrics:metrics-graphite:3.2.5'
compile 'io.jsonwebtoken:jjwt:0.6.0' compile 'io.jsonwebtoken:jjwt:0.6.0'
compile group: 'org.zeromq', name: 'jeromq', version: '0.4.0' compile group: 'org.zeromq', name: 'jeromq', version: '0.4.0'
......
...@@ -5,9 +5,10 @@ import com.codahale.metrics.Timer.Context; ...@@ -5,9 +5,10 @@ import com.codahale.metrics.Timer.Context;
import com.codahale.metrics.graphite.GraphiteReporter; import com.codahale.metrics.graphite.GraphiteReporter;
import com.codahale.metrics.graphite.PickledGraphite; import com.codahale.metrics.graphite.PickledGraphite;
import metrics_influxdb.HttpInfluxdbProtocol; //import metrics_influxdb.HttpInfluxdbProtocol;
import metrics_influxdb.InfluxdbReporter; import metrics_influxdb.InfluxdbReporter;
import metrics_influxdb.api.measurements.CategoriesMetricMeasurementTransformer; import metrics_influxdb.api.measurements.CategoriesMetricMeasurementTransformer;
import metrics_influxdb.api.protocols.HttpInfluxdbProtocol;
import microservice.MicroserviceApp; import microservice.MicroserviceApp;
import microservice.io.iface.IMetricsFactory; import microservice.io.iface.IMetricsFactory;
...@@ -161,7 +162,7 @@ public class IMetricsFactoryImpl implements IMetricsFactory ...@@ -161,7 +162,7 @@ public class IMetricsFactoryImpl implements IMetricsFactory
host = influxdb_hostport.substring(0, index); host = influxdb_hostport.substring(0, index);
} }
final ScheduledReporter reporter = InfluxdbReporter.forRegistry(metrics) final ScheduledReporter reporter = InfluxdbReporter.forRegistry(metrics)
.protocol(new HttpInfluxdbProtocol("http", host , port, influxdb_user, influxdb_pass, influxdb_dbname)) .protocol(new HttpInfluxdbProtocol(host , port, influxdb_user, influxdb_pass, influxdb_dbname))
.convertRatesTo(TimeUnit.SECONDS) .convertRatesTo(TimeUnit.SECONDS)
.convertDurationsTo(TimeUnit.MILLISECONDS) .convertDurationsTo(TimeUnit.MILLISECONDS)
.filter(MetricFilter.ALL) .filter(MetricFilter.ALL)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment