Documentation ¶ Overview ¶ Package metadata is a way of defining message headers Index ¶ func NewContext(ctx context.Context, md Metadata) context.Context type Metadata func Copy(md Metadata) Metadata func FromContext(ctx context.Context) (Metadata, bool) Constants ¶ This section is empty. Variables ¶ This section is empty. Functions ¶ func NewContext ¶ func NewContext(ctx context.Context, md Metadata) context.Context Types ¶ type Metadata ¶ type Metadata map[string]string Metadata is our way of representing request headers internally. They're used at the RPC level and translate back and forth from Transport headers. func Copy ¶ added in v0.21.0 func Copy(md Metadata) Metadata func FromContext ¶ func FromContext(ctx context.Context) (Metadata, bool) Source Files ¶ View all Source files metadata.go Click to show internal directories. Click to hide internal directories.