Top Description Interfaces Annotations Classes
[default module]

Package io.micrometer.context

Annotations
@NonNullApi
@NonNullFields

This package contains abstractions and implementations for context propagation.

Interface Summary

Modifier and TypeInterface and Description
public interface
ContextAccessor<
type of context for reading
READ
,
type of context for writing
WRITE
>

Contract to assist with access to an external, map-like context, such as the Project Reactor Context, including the ability to read values from it a Map and to write values to it from a Map.

public interface
ContextSnapshot

Holds values extracted from ThreadLocal and other types of context and exposes methods to propagate those values.

public interface
ContextSnapshotFactory

Factory for creating ContextSnapshot objects and restoring ThreadLocal values using a context object for which a ContextAccessor exists in the ContextRegistry.

public interface
ThreadLocalAccessor<V>

Contract to assist with setting and clearing a ThreadLocal.

Annotation Summary

Modifier and TypeAnnotation and Description
pack-priv @interface
NonNullApi

Declares all method parameters and return values within a package as non-nullable via JSR-305 meta-annotations to indicate nullability in Java.

pack-priv @interface
NonNullFields

Declares all fields within a package as non-nullable via JSR-305 meta-annotations to indicate nullability in Java.

pack-priv @interface
Nullable

Annotation to declare that a method parameter, return value, or field can be null under some circumstance.

Class Summary

Modifier and TypeClass and Description
public class
ContextExecutorService<EXECUTOR extends ExecutorService>

Wraps an ExecutorService in order to capture context via ContextSnapshot when a task is submitted, and propagate context to the task when it is executed.

public class
ContextRegistry

Registry that provides access to, instances of ContextAccessor and ThreadLocalAccessor.

public class
ContextScheduledExecutorService

Wraps a ScheduledExecutorService in order to capture context via ContextSnapshot when a task is submitted, and propagate context to the task when it is executed.

pack-priv class
DefaultContextSnapshot

Default implementation of ContextSnapshot.

pack-priv class