Package io.grpc.opentelemetry
Class MetadataGetter
java.lang.Object
io.grpc.opentelemetry.MetadataGetter
- All Implemented Interfaces:
io.opentelemetry.context.propagation.TextMapGetter<io.grpc.Metadata>
final class MetadataGetter
extends Object
implements io.opentelemetry.context.propagation.TextMapGetter<io.grpc.Metadata>
A TextMapGetter that reads value from gRPC
Metadata
. Supports both text and binary
headers. Supporting binary header is an optimization path for GrpcTraceBinContextPropagator
to work around the lack of binary propagator API and thus avoid
base64 (de)encoding when passing data between propagator API interfaces.-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
logger
-
INSTANCE
-
-
Constructor Details
-
MetadataGetter
MetadataGetter()
-
-
Method Details
-
getInstance
-
keys
- Specified by:
keys
in interfaceio.opentelemetry.context.propagation.TextMapGetter<io.grpc.Metadata>
-
get
- Specified by:
get
in interfaceio.opentelemetry.context.propagation.TextMapGetter<io.grpc.Metadata>
-
getBinary
-