
org.zalando.tracer.hystrix.TracerConcurrencyStrategy Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of tracer-hystrix Show documentation
Show all versions of tracer-hystrix Show documentation
Tracing requests through a distributed system.
package org.zalando.tracer.hystrix;
import com.netflix.hystrix.strategy.concurrency.HystrixConcurrencyStrategy;
import org.zalando.tracer.Tracer;
import java.util.concurrent.Callable;
public final class TracerConcurrencyStrategy extends ForwardingHystrixConcurrencyStrategy {
private final Tracer tracer;
private final HystrixConcurrencyStrategy delegate;
public TracerConcurrencyStrategy(final Tracer tracer, final HystrixConcurrencyStrategy delegate) {
this.tracer = tracer;
this.delegate = delegate;
}
@Override
protected HystrixConcurrencyStrategy delegate() {
return delegate;
}
@Override
public Callable wrapCallable(final Callable callable) {
return tracer.preserve(super.wrapCallable(callable));
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy