All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.lettuce.core.tracing.TraceContextProvider Maven / Gradle / Ivy

Go to download

Advanced and thread-safe Java Redis client for synchronous, asynchronous, and reactive usage. Supports Cluster, Sentinel, Pipelining, Auto-Reconnect, Codecs and much more.

The newest version!
package io.lettuce.core.tracing;

import reactor.core.publisher.Mono;

/**
 * Interface to obtain a {@link TraceContext} allowing propagation of {@link Tracer.Span} {@link TraceContext}s across threads.
 *
 * @author Mark Paluch
 * @since 5.1
 */
@FunctionalInterface
public interface TraceContextProvider {

    /**
     * @return the {@link TraceContext}.
     */
    TraceContext getTraceContext();

    /**
     * @return the {@link TraceContext}.
     */
    default Mono getTraceContextLater() {
        return Mono.justOrEmpty(getTraceContext());
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy