committed by
Spencer Gibb
parent
c89645e069
commit
fae60e9fae
@@ -24,7 +24,6 @@ import org.springframework.http.client.ClientHttpRequestExecution;
|
|||||||
import org.springframework.http.client.ClientHttpRequestInterceptor;
|
import org.springframework.http.client.ClientHttpRequestInterceptor;
|
||||||
import org.springframework.http.client.ClientHttpResponse;
|
import org.springframework.http.client.ClientHttpResponse;
|
||||||
|
|
||||||
import com.netflix.servo.MonitorRegistry;
|
|
||||||
import com.netflix.servo.monitor.MonitorConfig;
|
import com.netflix.servo.monitor.MonitorConfig;
|
||||||
import com.netflix.servo.tag.SmallTagMap;
|
import com.netflix.servo.tag.SmallTagMap;
|
||||||
import com.netflix.servo.tag.Tags;
|
import com.netflix.servo.tag.Tags;
|
||||||
@@ -41,18 +40,15 @@ public class MetricsClientHttpRequestInterceptor implements ClientHttpRequestInt
|
|||||||
* Boot (Actuator) provides a more general purpose abstraction for dimensional metrics
|
* Boot (Actuator) provides a more general purpose abstraction for dimensional metrics
|
||||||
* systems, this can be moved there and rewritten against that abstraction.
|
* systems, this can be moved there and rewritten against that abstraction.
|
||||||
*/
|
*/
|
||||||
private final MonitorRegistry registry;
|
private final ServoMonitorCache servoMonitorCache;
|
||||||
|
|
||||||
private final Collection<MetricsTagProvider> tagProviders;
|
private final Collection<MetricsTagProvider> tagProviders;
|
||||||
|
|
||||||
private final ServoMonitorCache servoMonitorCache;
|
|
||||||
|
|
||||||
private final String metricName;
|
private final String metricName;
|
||||||
|
|
||||||
public MetricsClientHttpRequestInterceptor(MonitorRegistry registry,
|
public MetricsClientHttpRequestInterceptor(
|
||||||
Collection<MetricsTagProvider> tagProviders,
|
Collection<MetricsTagProvider> tagProviders,
|
||||||
ServoMonitorCache servoMonitorCache, String metricName) {
|
ServoMonitorCache servoMonitorCache, String metricName) {
|
||||||
this.registry = registry;
|
|
||||||
this.tagProviders = tagProviders;
|
this.tagProviders = tagProviders;
|
||||||
this.servoMonitorCache = servoMonitorCache;
|
this.servoMonitorCache = servoMonitorCache;
|
||||||
this.metricName = metricName;
|
this.metricName = metricName;
|
||||||
|
|||||||
@@ -15,7 +15,6 @@ package org.springframework.cloud.netflix.metrics;
|
|||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
|
|
||||||
import com.netflix.servo.MonitorRegistry;
|
|
||||||
import org.aspectj.lang.JoinPoint;
|
import org.aspectj.lang.JoinPoint;
|
||||||
import org.springframework.beans.BeansException;
|
import org.springframework.beans.BeansException;
|
||||||
import org.springframework.beans.factory.annotation.Value;
|
import org.springframework.beans.factory.annotation.Value;
|
||||||
@@ -85,9 +84,9 @@ public class MetricsInterceptorConfiguration {
|
|||||||
|
|
||||||
@Bean
|
@Bean
|
||||||
MetricsClientHttpRequestInterceptor spectatorLoggingClientHttpRequestInterceptor(
|
MetricsClientHttpRequestInterceptor spectatorLoggingClientHttpRequestInterceptor(
|
||||||
MonitorRegistry registry, Collection<MetricsTagProvider> tagProviders,
|
Collection<MetricsTagProvider> tagProviders,
|
||||||
ServoMonitorCache servoMonitorCache) {
|
ServoMonitorCache servoMonitorCache) {
|
||||||
return new MetricsClientHttpRequestInterceptor(registry, tagProviders,
|
return new MetricsClientHttpRequestInterceptor(tagProviders,
|
||||||
servoMonitorCache, this.metricName);
|
servoMonitorCache, this.metricName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user