public class ThresholdLoggingTracer extends Object implements RequestTracer
Modifier and Type | Class and Description |
---|---|
static class |
ThresholdLoggingTracer.Builder
The builder used to configure the
ThresholdLoggingTracer . |
Modifier and Type | Method and Description |
---|---|
static ThresholdLoggingTracer.Builder |
builder(EventBus eventBus)
Deprecated.
please use
create(EventBus, ThresholdLoggingTracerConfig) instead. |
ThresholdLoggingTracerConfig |
config()
Returns the current configuration.
|
static ThresholdLoggingTracer |
create(EventBus eventBus)
Short-hand to create the tracer with the event bus that needs to be used.
|
static ThresholdLoggingTracer |
create(EventBus eventBus,
ThresholdLoggingTracerConfig config)
Creates a tracer with config and a reference to the event bus.
|
RequestSpan |
requestSpan(String name,
RequestSpan parent)
Creates a new request span with or without a parent.
|
Mono<Void> |
start()
Starts the tracer if it hasn't been started, might be a noop depending on the implementation.
|
Mono<Void> |
stop(Duration timeout)
Stops the tracer if it has been started previously, might be a noop depending on the implementation.
|
public static ThresholdLoggingTracer.Builder builder(EventBus eventBus)
create(EventBus, ThresholdLoggingTracerConfig)
instead.eventBus
- the event bus where the final events will be emitted into.public static ThresholdLoggingTracer create(EventBus eventBus)
eventBus
- the event bus where the final events will be emitted into.public static ThresholdLoggingTracer create(EventBus eventBus, ThresholdLoggingTracerConfig config)
eventBus
- the event bus where the final events will be emitted into.config
- the config that should be used.public ThresholdLoggingTracerConfig config()
public RequestSpan requestSpan(String name, RequestSpan parent)
RequestTracer
requestSpan
in interface RequestTracer
name
- the name of the toplevel operation (i.e. "cb.get")parent
- a parent, if no parent is used supply null.public Mono<Void> start()
RequestTracer
start
in interface RequestTracer
public Mono<Void> stop(Duration timeout)
RequestTracer
stop
in interface RequestTracer
Copyright © 2024 Couchbase, Inc.. All rights reserved.