Documentation
¶
Index ¶
- func Delete(ctx context.Context, k string) context.Context
- func Get(ctx context.Context, key string) (string, bool)
- func MergeContext(ctx context.Context, patchMd Metadata, overwrite bool) context.Context
- func NewContext(ctx context.Context, md Metadata) context.Context
- func Set(ctx context.Context, k, v string) context.Context
- type Metadata
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MergeContext ¶
MergeContext merges metadata to existing metadata, overwriting if specified
func NewContext ¶
NewContext creates a new context with the given metadata
Types ¶
type Metadata ¶
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 FromContext ¶
FromContext returns metadata from the given context
Click to show internal directories.
Click to hide internal directories.